Documentation forKiwi CatTools

Kiwi CatTools API: Database class

The Database class is used to connect to the CatTools database. In doing so, this class also verifies your license. The database that the API connects to is the same as the one stored in your KiwiCatTools-Settings.ini file.

Properties

Version The version of the API.dll file. Read Only
Path The database being accessed. This is evaluated from your .ini file. Read Only

EncryptionPassword

The encryption password needed to decrypt the database.

 
Err

The ID of the last error encountered.

Read Only
ErrDescription

The last error encountered.

Read Only
Connected

Verifies the database is connected.

Read Only

Methods

OpenConnection

Opens a connection to the database as defined in your .ini file.

CloseConnection

Closes the connection to the database.

Devices

A collection of the devices contained in the database.

ErrClear

Clears any error messages.

DeviceTypes

A collection of the device types contained in the database.

Groups

A collection of the groups contained in the database.

Example: Connect to a database using CatTools API

The following sample Visual Basic code showing you how to connect to your database using the CatTools API.

Dim DB As CatToolsAPI.Database
Set DB = New CatToolsAPI.Database

DB.EncryptionPassword = "MyPassword"

If DB.OpenConnection Then
	MsgBox "Connected ok"
Else
	MsgBox "DB connection failed: " & DB.ErrDescription
End If

DB.CloseConnection
Set DB = Nothing