I need to develop my own interface to let an user create a new DB Engine on a WIN platform, without using the Control Center utilities.
This functionality will be added as a part of an already existing interface, written in Java.
To do that, i'd need:
- either a command like the linux "dbmaint a ..."
- or a class (contained in jdbc jar?) with some methods like "setEngineName", "setDictionaryPath" and so on...
What I'm asking is:
does something like this exist? are there other ways to accomplish the same? do I have to give up?
There isn't a tool that I'm aware of.
You could write your own using DTI/DTO.
I've never used DTI/DTO...
is it possible to use them in Java code?
can you suggest me a link where I can find some documentation (examples, possibly) about them?
Why don't you want to use the Control Center?
Because I'm developing a configuration tool for an existing application, and in this tool the creation of a db engine is one of the several steps the final user must follow.... thus, I would like to encapsulate the creation of the db in a "proprietary" gui.
Hope it's clear...
Thanks for your help (and thanks in advance if you'll answer again!).
The DTI/DTO page at Pervasive's page (http://www.pervasive.com/developerzo...ods/dtidto.asp) is the best resource I can give. I'm not a Java programmer so I can't tell you if it can be called through Java.
I have used both DTI and DTO to create both Pervasive Database Names and Pervasive ODBC Engine Interface entries. I've also used the ODBC API (SQLConfigDatasource) to create client DSNs but that was in C and VB.
Certified Pervasive Developer
Certified Pervasive Technician
Custom Btrieve/VB development http://www.mirtheil.com
I do not answer questions by email. Please post on the forum.
I succeed in getting the connection, and from the resulting object I can "see" the databases registered on the system.
Then, I try to create the Database, setting the requested parameters... but the creation fails, returning me an Access Violation error (my thread seems not to have the permission to read the location of the virtual memory).
At the moment, can't understand if the error is given by the interface built with JaWin or by my code, perhaps because of some wrong parameter...
What I'm asking is:
- What's the meaning of the "DTO.DtoSession.1" and "DTO.DtoDatabase.1" strings, passed as parameters in the CreateObject methods?
- Are access violation errors possible also in COM programming? If so, what would you suggest me to check?
- Are there other aspects I should have to take care of (such as inizializations, allocating and so on), if I ran the InstallScript Sample linked above?