IVsDataConnectionManager.GetConnection Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
GetConnection(Guid, String, Boolean) |
Retrieves an existing data connection or creates a new data connection that matches the specified provider GUID and connection string. |
GetConnection(Guid, String, Boolean, Boolean) |
Retrieves an existing data connection or creates a new data connection that matches the specified provider GUID and connection string. Also, optionally updates the connection string of the returned connection. |
GetConnection(Guid, String, Boolean)
Retrieves an existing data connection or creates a new data connection that matches the specified provider GUID and connection string.
public:
Microsoft::VisualStudio::Data::Services::IVsDataConnection ^ GetConnection(Guid provider, System::String ^ connectionString, bool encryptedString);
public Microsoft.VisualStudio.Data.Services.IVsDataConnection GetConnection (Guid provider, string connectionString, bool encryptedString);
abstract member GetConnection : Guid * string * bool -> Microsoft.VisualStudio.Data.Services.IVsDataConnection
Public Function GetConnection (provider As Guid, connectionString As String, encryptedString As Boolean) As IVsDataConnection
Parameters
- provider
- Guid
The GUID of the DDEX provider.
- connectionString
- String
The connection string in unencrypted or encrypted form.
- encryptedString
- Boolean
A Boolean value indicating whether the connection string is encrypted (true) or unencrypted (false).
Returns
An IVsDataConnection object representing the data connection.
Applies to
GetConnection(Guid, String, Boolean, Boolean)
Retrieves an existing data connection or creates a new data connection that matches the specified provider GUID and connection string. Also, optionally updates the connection string of the returned connection.
public:
Microsoft::VisualStudio::Data::Services::IVsDataConnection ^ GetConnection(Guid provider, System::String ^ connectionString, bool encryptedString, bool update);
public Microsoft.VisualStudio.Data.Services.IVsDataConnection GetConnection (Guid provider, string connectionString, bool encryptedString, bool update);
abstract member GetConnection : Guid * string * bool * bool -> Microsoft.VisualStudio.Data.Services.IVsDataConnection
Public Function GetConnection (provider As Guid, connectionString As String, encryptedString As Boolean, update As Boolean) As IVsDataConnection
Parameters
- provider
- Guid
The GUID of the DDEX provider.
- connectionString
- String
The connection string in unencrypted or encrypted form.
- encryptedString
- Boolean
A Boolean value indicating whether the connection string is encrypted (true) or unencrypted (false).
- update
- Boolean
A Boolean value indicating whether the data connection's connection string value should be updated with the specified connection string (true) or not (false).
Returns
An IVsDataConnection object representing the data connection.