次の方法で共有


DbSyncAdapter.RowIdColumns プロパティ

テーブルの各行に対応する一意な ID を構成する列の名前のコレクションを取得します。

名前空間: Microsoft.Synchronization.Data
アセンブリ: Microsoft.Synchronization.Data (microsoft.synchronization.data.dll 内)

構文

'宣言
Public ReadOnly Property RowIdColumns As Collection(Of String)
'使用
Dim instance As DbSyncAdapter
Dim value As Collection(Of String)

value = instance.RowIdColumns
public Collection<string> RowIdColumns { get; }
public:
property Collection<String^>^ RowIdColumns {
    Collection<String^>^ get ();
}
/** @property */
public Collection<String> get_RowIdColumns ()
public function get RowIdColumns () : Collection<String>

プロパティ値

テーブルの各行に対応する一意な ID を構成する列の名前のコレクション。

次のコード例では、Customer テーブルの SyncAdapter オブジェクトを作成し、CustomerId 列を使用してテーブルの各行を識別するように指定します。

DbSyncAdapter adapterCustomer = new DbSyncAdapter("Customer");


//Specify the primary key, which Sync Framework uses
//to identify each row during synchronization.
adapterCustomer.RowIdColumns.Add("CustomerId");
Dim adapterCustomer As New DbSyncAdapter("Customer")

'Specify the primary key, which Sync Framework uses
'to identify each row during synchronization.
adapterCustomer.RowIdColumns.Add("CustomerId")

参照

リファレンス

DbSyncAdapter クラス
DbSyncAdapter メンバー
Microsoft.Synchronization.Data 名前空間