Method
Closes the database that is open.
Category
Database
Syntax
Sub CloseDatabase
'Closes a company and disconnects from the server or closes the database
CF1.CloseCompany
logWr "CloseCompany: OK"
If .Text1(cf.ServerName) <> "" Then
CF1.DisconnectServer
logWr "Disconnected from Server"
Else
CF1.CloseDatabase
logWr "Database Closed"
End If
Comments
Closes the database that was opened with OpenDatabase.
CloseDatabase will raise an exception if there are any open tables or allocated records when the function is called. See also ReleaseAllObjects.