Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

ConnectionString Property [Access 2003 VBA Language Reference]

Office 2003

You can use the ConnectionString property returns the base connection string for the DataAccessPage object. Read/write String.

expression.ConnectionString

expression Required. An expression that returns one of the objects in the Applies To list.

Remarks

The ConnectionString property is available only by using Visual Basic and is read-only.

The ConnectionString property returns the connection string that was set through the OpenConnection method or by clicking Connection on the File menu. When making a connection, Microsoft Access project modifies the ConnectionString property for use with the ADO environment. The Microsoft Office Data Source Control (MSODSC) likewise modifies the ConnectionString.

Example

The following example displays the ConnectionString property setting of the currently active data access page:

Dim objCurrent As Object
Set objCurrent = Application.DataAccessPages(0)
MsgBox "The current base connection is " _
    & objCurrent.ConnectionString
		




Show:
© 2014 Microsoft