Product Documentation

VCL/CLX Developers Guide

Previous Topic

Next Topic

Methods

Create

constructor Create(AOwner : TComponent);

The TCtDatabase component constructor.

Destroy

destructor Destroy();

The TCtDatabase component destructor. Do not call Destroy directly. The object must be destroyed with the inherited (TObject) Free() method.

AddDatabase

procedure AddDatabase();

Add an existing database to the session. The Database, Directory and Session properties must be set before this method is called.

CloseAll

procedure CloseAll();

Close all open tables associated with this database.

Connect

procedure Connect();

Connect the database to a session. The Database and Session properties must be set before calling this method.

CreateDatabase

procedure CreateDatabase();

Create a new database for this session. The Database, Directory and Session properties must be set before calling this method.

DeleteDatabase

procedure DeleteDatabase();

Drop a database from a session and delete the database dictionary file from disk. Set the Database and Session properties before calling this method.

Disconnect

procedure Disconnect();

Disconnects the database from a session.

DropDatabase

procedure DropDatabase();

Drop a database from a session. This method only removes the database entry in the session dictionary. The database dictionary file is not deleted. Set the Database and Session properties before calling this method.

RenameTable

procedure RenameTable(FOldName : string; FNewName : string);

  • FOldName - the current name of the table.
  • FNewName - the new name to be given to the table.

RenameTable() renames a c-treeVCL table. The Rename() function attempts to open the table in exclusive mode. The table must be closed and opened with exclusive access to rename the physical file resources. Error FCNF_COD (-8) is generally returned should the file already be open. Rename() returns with the table closed once the rename operation is complete.

TOCIndex