Connecting to a Database Server
Go Up to Controlling Connections
There are two ways to connect to a database server using a database component:
- Call the
- Set the
True executes the
Open verifies that the database specified by the
Directory properties exists, and if an
OnLogin event exists for the database component, it is executed. Otherwise, the default Login dialog box appears.
Once a database connection is established the connection is maintained as long as there is at least one active dataset. If a dataset is later opened which uses the database, the connection must be reestablished and initialized. An event notifier procedure can be constructed to indicate whenever a connection to the database is made or broken.