Use the DIALOG_DBCONNECT function to connect to the DBMS via the standard ODBC dialog boxes. You will be prompted for information required to connect to the desired database.

Syntax


status = DIALOG_DBCONNECT(DBobj [, DATASOURCE=string] [, USER_ID=string] [, PASSWORD=string]
[, DIALOG_PARENT=widget id] )

Return Value


The function returns true (1) unless you selected the dialog’s Cancel button, in which case it returns false (0).

Arguments


DBobj

A valid IDLdbDatabase object that is not already connected to a data source.

Keywords


DATASOURCE

Set this keyword equal to the name of a data source to which you wish to connect. (If you do not know the data source name in advance, you can use the GetDatasources method of the IDLdbDatabase object to retrieve a list of available data sources.)

USER_ID

Set this keyword equal to the user login name or ID used to log into the datasource.

PASSWORD

Set this keyword equal to the password corresponding to the user ID.

DIALOG_PARENT

Set this keyword equal to the widget ID of a widget over which the dialog should be positioned.

Version History


5.0

Introduced