Product Documentation

c-treeDB API for C# - Developers Guide

Previous Topic

Next Topic

CTSession.SetConfigurationFile

Sets the server .dll configuration file name and path if it's not located in the local working directory for the application that is loading the Server DLL. Note this function must be called before the Server DLL is loaded (e.g., started).

Declaration

CTDBRET CTSession.SetConfigurationFile(void)

Description

SetConfigurationFile() sets the server .dll configuration file name and path.

Returns

Returns CTDBRET_OK on success, or throws a c-treeDB .NET exception on failure.

Example

try

{

CTSession.SetConfigurationFile("ctsrvr.cfg");

CTSession.StartDatabaseEngine();

} catch (CTException ex)

{

HandleException();

}

...

...

try

{

CTSession.StopDatabaseEngine();

} catch (CTException ex)

{

HandleException();

}

See also

CTSession.StartDatabaseEngine(), CTSession.StopDatabaseEngine()

TOCIndex