SqlConnection Constructor (String^, SqlCredential^)
Initializes a new instance of the SqlConnection class given a connection string, that does not use Integrated Security = true and a SqlCredential object that contains the user ID and password.
Assembly: System.Data (in System.Data.dll)
Parameters
- connectionString
-
Type:
System::String^
A connection string that does not use any of the following connection string keywords: Integrated Security = true, UserId, or Password; or that does not use ContextConnection = true.
- credential
-
Type:
System.Data.SqlClient::SqlCredential^
A SqlCredential object. If credential is null, SqlConnection is functionally equivalent to SqlConnection.
Available since 4.5