Disconnecting from a Database Server
Go Up to Controlling Connections
There are two ways to disconnect a server from a database component:
- Set the
Connectedproperty toFalse - Call the
Closemethod
Setting Connected to False calls Close. Close closes all open datasets and disconnects from the server. For example, the following code closes all active datasets for a database component and drops its connections:
IBDatabase1.Connected := False;