J:
If you look at the SyncServices_CSharp_DownloadOnly app and specifically,
the Constructor for the SampleServerSyncProvider - just replace the code in
the middle where you actually delcare the SqlSyncAdapterBuilder to the code
below:
Basically, you add a FilterClause (and if it's parameterized, you can add a
SqlParameter - I was a bum and used concatenated sql which I should be
flogged for, but I wanted to whip something up quick this evening before I
signed off. To get the sample code to do the whole thing with a 'real'
param, there's a demo here
ms-help://MS.SynchronizationServices.v1.EN/syncdata1/html/15abacc8-a243-4570-86e9-da95bb5bfddd.htm
on BOL for Syn Services
//Instantiate a synchronization adapter builder, which
//queries the tables to be synchronized and builds the
//synchronization adapter and commands required to
//perform synchronization.
SqlSyncAdapterBuilder builder = new
SqlSyncAdapterBuilder((SqlConnection)this.Connection);
//Add the Customer table and its tombstone table, and
String filterCommand = "CustomerName='Sharp Bikes'";
//specify synchronization direction.
builder.TableName = "Sales.Customer";
builder.TombstoneTableName = builder.TableName + "_Tombstone";
builder.FilterClause = filterCommand ;
builder.TombstoneFilterClause = filterCommand;