DataConnection.ConnectionString property (Visio)

Gets or sets the connection string that you can use to access an existing DataConnection object or to create a new DataConnection object. Read/write.

Note

This Visio object or member is available only to licensed users of Visio Professional 2013.

Syntax

expression.ConnectionString

expression An expression that returns a DataConnection object.

Return value

String

Remarks

The value of the ConnectionString property for a given DataRecordset object is the same string that you would pass to the DataRecordsets.Add method to create the data recordset.

The easiest way to determine an appropriate connection string for a particular data source is to use the Data Selector Wizard in the Visio user interface (UI) to make the same connection, recording a macro while running the wizard, and then copying the connection string from the macro code.

Setting the ConnectionString property to a new value has no effect on data already in any data recordsets. To update the data in a data recordset using a new ConnectionString setting, call the DataRecordset.Refresh method.

Support and feedback

Have questions or feedback about Office VBA or this documentation? Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.