SqlUserInteractionServices.TryConstructConnectionStringAndProvider – metoda
Lze získat SQL Server -specifický připojovací řetězec a SQL Server zprostředkovatele
Obor názvů: Microsoft.Data.Schema.Sql
Sestavení: Microsoft.Data.Schema.Sql (v Microsoft.Data.Schema.Sql.dll)
Syntaxe
'Deklarace
Public Overrides Function TryConstructConnectionStringAndProvider ( _
connectionString As String, _
databaseName As String, _
<OutAttribute> ByRef provider As Guid, _
<OutAttribute> ByRef formattedConnectionString As String _
) As Boolean
public override bool TryConstructConnectionStringAndProvider(
string connectionString,
string databaseName,
out Guid provider,
out string formattedConnectionString
)
public:
virtual bool TryConstructConnectionStringAndProvider(
String^ connectionString,
String^ databaseName,
[OutAttribute] Guid% provider,
[OutAttribute] String^% formattedConnectionString
) override
abstract TryConstructConnectionStringAndProvider :
connectionString:string *
databaseName:string *
provider:Guid byref *
formattedConnectionString:string byref -> bool
override TryConstructConnectionStringAndProvider :
connectionString:string *
databaseName:string *
provider:Guid byref *
formattedConnectionString:string byref -> bool
public override function TryConstructConnectionStringAndProvider(
connectionString : String,
databaseName : String,
provider : Guid,
formattedConnectionString : String
) : boolean
Parametry
- connectionString
Typ: System.String
Připojovací řetězec.
- databaseName
Typ: System.String
Název databáze, ke které se připojujete.
- provider
Typ: System.Guid%
Vrácené GUID zprostředkovatele.
- formattedConnectionString
Typ: System.String%
Vrácené formátovaný připojovací řetězec.
Vrácená hodnota
Typ: System.Boolean
true Pokud metoda byla sestavit připojovací řetězec a získat správný identifikátor GUID.
Poznámky
Tyto informace slouží k přidání připojení Server Explorer.
Zabezpečení rozhraní .NET Framework
- Plná důvěra přímému volajícímu. Částečně zabezpečený kód nemůže tento člen použít. Další informace naleznete v tématu Používání knihoven z částečně důvěryhodného kódu.