Kiwi CatTools API: Groups class
The Groups class is used to enumerate CatTools Group objects.
Returns the number of device types in your database.
The collection of Group objects.
Resyncronise with the database.
Sort the collection of Group objects in ascending or descending order.
You can only enumerate Groups you can not add edit or delete them using this object. To add a Group simply give the text value to your Device and when it is saved the Group will be created.
The following sample Visual Basic code shows you how to list the Groups found in your database using the CatTools API.
Dim DB As CatToolsAPI.Database Dim Groups As CatToolsAPI.Groups Dim Group As CatToolsAPI.Group Set DB = New CatToolsAPI.Database DB.OpenConnection If DB.Connected Then Set Groups = DB.Groups If Not Groups Is Nothing Then Debug.Print Groups.Count & " groups in the database" For Each Group In Groups Debug.Print "->" & Group.Name DoEvents Next Else Msgbox "Error:" & DB.ErrDescription End If Else Msgbox "Connection failed: " & DB.ErrDescription End If DB.CloseConnection Set Group = Nothing Set Groups = Nothing Set DB = Nothing