DbSyncProvider.ScopeName Property
Gets or sets the name of the scope to synchronize.
This property is not CLS-compliant.
Namespace: Microsoft.Synchronization.Data
Assembly: Microsoft.Synchronization.Data (in microsoft.synchronization.data.dll)
Syntax
'Declaration
Public Property ScopeName As String
'Usage
Dim instance As DbSyncProvider
Dim value As String
value = instance.ScopeName
instance.ScopeName = value
public string ScopeName { get; set; }
public:
property String^ ScopeName {
String^ get ();
void set (String^ value);
}
/** @property */
public String get_ScopeName ()
/** @property */
public void set_ScopeName (String value)
public function get ScopeName () : String
public function set ScopeName (value : String)
Property Value
The name of the scope, which is a set of objects to synchronize.
Remarks
For peer-to-peer database synchronization, a scope is typically a set of tables. For more information about how scope is used, see "Creating Tracking Tables to Store Metadata" in How to: Configure Change Tracking and Synchronize Peers.
Example
The following code example specifies the scope for a DbSyncProvider object in the SetupSyncProvider
method that was created for this documentation. This method is used so that providers can be configured easily for multiple peers. To view this code in the context of a complete example, see How to: Configure Change Tracking and Synchronize Peers.
SqlConnection peerConnection = new SqlConnection(peerConnString);
peerProvider.Connection = peerConnection;
peerProvider.ScopeName = "Sales";
Dim peerConnection As New SqlConnection(peerConnString)
peerProvider.Connection = peerConnection
peerProvider.ScopeName = "Sales"
See Also
Reference
DbSyncProvider Class
DbSyncProvider Members
Microsoft.Synchronization.Data Namespace