다음을 통해 공유


SqlCeRemoteDataAccess.InternetPassword Property

SQL Server Compact 3.5 서버 에이전트에 연결할 때 사용되는 Microsoft 인터넷 정보 서비스(IIS) 암호를 지정합니다.

네임스페이스: System.Data.SqlServerCe
어셈블리: System.Data.SqlServerCe(system.data.sqlserverce.dll에 있음)

구문

‘선언
Public Property InternetPassword As String
public string InternetPassword { get; set; }
public:
property String^ InternetPassword {
    String^ get ();
    void set (String^ value);
}
/** @property */
public String get_InternetPassword ()

/** @property */
public void set_InternetPassword (String value)
public function get InternetPassword () : String

public function set InternetPassword (value : String)

속성 값

SQL Server Compact 3.5 서버 에이전트에 연결할 때 사용되는 IIS 암호 문자열입니다. 기본적으로 암호는 사용하지 않습니다.

주의

기본 인증 또는 Windows 통합 인증을 사용하도록 SQL Server Compact 3.5 서버 에이전트를 구성하는 경우 InternetPassword 속성이 필요합니다. Windows 통합 인증이 사용되는 경우 InternetPassword는 네트워크에서 전달되지 않습니다.

기본 인증을 사용할 때는 사용자 암호를 보호하기 위해 SSL이나 PCT(Private Communication Technology) 암호화를 사용하도록 IIS를 구성해야 합니다. SSL이나 PCT 암호화가 없으면 기본 인증에서는 일반 텍스트 형태로 네트워크에서 암호를 전송합니다. 이런 경우 안전하지 않으므로 기본 인증을 사용할 때는 항상 SSL이나 PCT 암호화를 사용하여 암호를 보호해야 합니다.

다음 예제에서는 SqlCeRemoteDataAccess 개체의 InternetPassword 속성을 설정하는 방법을 보여 줍니다.

' Connection String to the SQL Server
'
Dim rdaOleDbConnectString As String = "Data Source=MySqlServer;Initial Catalog=AdventureWorks; " & _
    "User Id=username;Password = <password>"

' Initialize RDA Object
'
Dim rda As SqlCeRemoteDataAccess = Nothing

Try
    ' Try the Pull Operation
    '
    rda = New SqlCeRemoteDataAccess( _
        "https://www.adventure-works.com/sqlmobile/sqlcesa35.dll", _
        "MyLogin", _
        "<password>", _
        "Data Source=MyDatabase.sdf")

    rda.Pull("Employees", "SELECT * FROM DimEmployee", rdaOleDbConnectString, _
        RdaTrackOption.TrackingOnWithIndexes, "ErrorTable")

    ' or, try one of these overloads:
    ' rda.Pull("Employees", "SELECT * FROM DimEmployee", rdaOleDbConnectString, _
    '     RdaTrackOption.TrackingOnWithIndexes)
    '
    ' rda.Pull("Employees", "SELECT * FROM DimEmployee", rdaOleDbConnectString)

Catch
    ' Handle errors here
    '
Finally
    ' Dispose of the RDA object
    '
    rda.Dispose()
End Try
// Connection String to the SQL Server
//
string rdaOleDbConnectString = "Data Source=MySqlServer;Initial Catalog=AdventureWorks; " +
    "User Id=username;Password = <password>";

// Initialize RDA Object
//
SqlCeRemoteDataAccess rda = null;

try
{
    // Try the Pull Operation
    //
    rda = new SqlCeRemoteDataAccess(
        "https://www.adventure-works.com/sqlmobile/sqlcesa35.dll",
        "MyLogin",
        "<password>",
        "Data Source=MyDatabase.sdf");

    rda.Pull("Employees", "SELECT * FROM DimEmployee", rdaOleDbConnectString,
        RdaTrackOption.TrackingOnWithIndexes, "ErrorTable");

    // or, try one of these overloads:
    //
    // rda.Pull("Employees", "SELECT * FROM DimEmployee", rdaOleDbConnectString,
    //     RdaTrackOption.TrackingOnWithIndexes);
    //
    // rda.Pull("Employees", "SELECT * FROM DimEmployee", rdaOleDbConnectString);
}
catch (SqlCeException)
{
    // Handle errors here
    //
}
finally
{
    // Dispose of the RDA object
    //
    rda.Dispose();
}

스레드 보안

이 유형의 모든 public static(Microsoft Visual Basic의 경우 공유) 멤버는 스레드로부터 안전합니다. 인스턴스 멤버는 스레드로부터의 안전성이 보장되지 않습니다.

플랫폼

개발 플랫폼

Windows Vista, Windows Mobile 5.0, Windows XP Professional with Service Pack 2 (SP2), Windows Server 2003, Windows Mobile 2003 for Pocket PC, Windows CE 5.0
버전 정보
.NET Framework 및 NET Compact Framework
3.5에서 지원됨
.NET Framework
3.0에서 지원됨
.NET Compact Framework 및 .Net Framework
2.0에서 지원됨

참고 항목

참조

SqlCeRemoteDataAccess Class
SqlCeRemoteDataAccess Members
System.Data.SqlServerCe Namespace