Contents Index OpenConnection method ULDatabaseSchema class

UltraLite ActiveX User's Guide
  UltraLite ActiveX API Reference
    ULDatabaseManager class

OpenConnectionWithParms method


Prototype 

OpenConnectionWithParms( connparms As ULConnectionParms) As ULConnection
Member of UltraliteActiveX.ULDatabaseManager

Description 

If a database exists, use this method to receive a connection. If a database does not exist, or the connection parameters are invalid, the call will fail. Use the error object to determine why the call failed.

The function returns a ULConnection object which provides an open connection to a specified UltraLite database. The database filename is specified using the connparms object. Parameters are specified using a sequence of name=value pairs. If no user ID or password is given, the default is used.

Parameters 

connparms    The parameters defining this connection.

Returns 

The ULConnection object is returned if the connection was successful.

Example 

The following example assumes you have created a ULConnectionParms object LoginParms and have specified the database locations and schema locations.

' eMbedded Visual Basic
Set DatabaseMgr = CreateObject("UltraLite.ULDatabaseManager")
Set Connection = DatabaseMgr.OpenConnection(LoginParms)
// JScript
DatabaseMgr = new ActiveXObject("UltraLite.ULDatabaseManager");
Connection = DatabaseMgr.OpenConnection(LoginParms);

Contents Index OpenConnection method ULDatabaseSchema class