SyncConfiguration Class

Maintains the collections of tables and parameters that are required to configure the client and server synchronization providers.

Namespace: Microsoft.Synchronization.Data
Assembly: Microsoft.Synchronization.Data (in

public class SyncConfiguration
/** @attribute SerializableAttribute() */ 
public class SyncConfiguration
public class SyncConfiguration


The following code example is from a class that derives from SyncAgent. The code creates two synchronization groups and three synchronization tables. The Customer table is added to the Customer group and the OrderHeader and OrderDetail tables are added to the Order group. All tables are download-only. If a table exists at the client, the table is dropped and re-created during the initial synchronization. To view this code in the context of a complete example, see How to: Filter Rows and Columns.

//Create two SyncGroups so that changes to OrderHeader
//and OrderDetail are made in one transaction. Depending on
//application requirements, you might include Customer
//in the same group.
SyncGroup customerSyncGroup = new SyncGroup("Customer");
SyncGroup orderSyncGroup = new SyncGroup("Order");

//Add each table: specify a synchronization direction of
SyncTable customerSyncTable = new SyncTable("Customer");
customerSyncTable.CreationOption = TableCreationOption.DropExistingOrCreateNewTable;
customerSyncTable.SyncDirection = SyncDirection.DownloadOnly;
customerSyncTable.SyncGroup = customerSyncGroup;

SyncTable orderHeaderSyncTable = new SyncTable("OrderHeader");
orderHeaderSyncTable.CreationOption = TableCreationOption.DropExistingOrCreateNewTable;
orderHeaderSyncTable.SyncDirection = SyncDirection.DownloadOnly;
orderHeaderSyncTable.SyncGroup = orderSyncGroup;

SyncTable orderDetailSyncTable = new SyncTable("OrderDetail");
orderDetailSyncTable.CreationOption = TableCreationOption.DropExistingOrCreateNewTable;
orderDetailSyncTable.SyncDirection = SyncDirection.DownloadOnly;
orderDetailSyncTable.SyncGroup = orderSyncGroup;

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Development Platforms

For a list of the supported platforms, see Hardware and Software Requirements (Synchronization Services).

Target Platforms