Connects to a data source.
VBA / VB.NET
object.Connect(Datasource [, Username] [, Password] [, Prompt])
Type: DbConnect
The object or objects this method applies to.
Type: String; input-only
The name of a .udl file in the Data Links directory.
Type: String; input-only; optional
User name with which you are connecting.
Type: String; input-only; optional
Password for connecting.
Type: Boolean; input-only; optional
Specifies whether users are prompted to specify connection properties.
If the data source is already connected, nothing happens.