Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
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.
Namespace: Microsoft.VisualStudio.Data.Services
Assembly: Microsoft.VisualStudio.Data.Services (in Microsoft.VisualStudio.Data.Services.dll)
Syntax
'Declaration
Function GetConnection ( _
provider As Guid, _
connectionString As String, _
encryptedString As Boolean, _
update As Boolean _
) As IVsDataConnection
IVsDataConnection GetConnection(
Guid provider,
string connectionString,
bool encryptedString,
bool update
)
IVsDataConnection^ GetConnection(
Guid provider,
String^ connectionString,
bool encryptedString,
bool update
)
abstract GetConnection :
provider:Guid *
connectionString:string *
encryptedString:bool *
update:bool -> IVsDataConnection
function GetConnection(
provider : Guid,
connectionString : String,
encryptedString : boolean,
update : boolean
) : IVsDataConnection
Parameters
provider
Type: System.GuidThe GUID of the DDEX provider.
connectionString
Type: System.StringThe connection string in unencrypted or encrypted form.
encryptedString
Type: System.BooleanA Boolean value indicating whether the connection string is encrypted (true) or unencrypted (false).
update
Type: System.BooleanA Boolean value indicating whether the data connection's connection string value should be updated with the specified connection string (true) or not (false).
Return Value
Type: Microsoft.VisualStudio.Data.Services.IVsDataConnection
An IVsDataConnection object representing the data connection.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.