PROPERTY:

 

 

 

 

 

 

 

DESCRIPTION:

 

 

Connection statement that describes parameters used to establish a connection with data source.

 

 

 

 

PROPERTY OF:

 

 

ADODatabase

 

 

ADOQuery

 

 

ADOTable

 

 

ADOStoredProc

 

 

ADODataShape

 

 

 

 

DEFAULT VALUE:

 

 

Empty string

 

 

 

 

 

DESCRIPTION:

 

 

Use the connectionString property to specify a data source by passing a detailed connection string containing a series of argument = value statements separated by semicolons.

 

ADO supports five arguments for the connectionString property; any other arguments pass directly to the provider without any processing by ADO.

 

The arguments ADO supports are as follows.

 

 

 

Argument:

DESCRIPTION:

 

Provider=

Specifies the name of a provider to use for the connection.

 

File Name=

Specifies the name of a provider-specific file (for example, a persisted data source object) containing preset connection information.

 

Remote Provider=

Specifies the name of a provider to use when opening a client-side connection. (Remote Data Service only.)

 

Remote Server=

Specifies the path name of the server to use when opening a client-side connection. (Remote Data Service only.)

 

URL=

Specifies the connection string as an absolute URL identifying a resource, such as a file or directory.

 

 

 

 

 

 

After you set the connectionString property and open the data object, the provider may alter the contents of the property.

 

 

 

Because the File Name argument causes ADO to load the associated provider, you cannot pass both the Provider and File Name arguments.

 

 

 

Duplicates of an argument in the connectionString property are ignored. The last instance of any argument is used.

 

 

 

The connectionString property is read/write when the connection is closed and read-only when it is open.

 

 

 

A connection string may be saved to UDL file for later use. Specify only the name of such a file in connectionString property to reuse a saved connection string.

 

 

 

The connection string may also contain login information such as User ID and Password, for automated logins.