Is there any way to see the pending status prior to doing a sync? RRS feed

  • Question

  • I see how to get SyncOperationStatistics from a sync operation, but I'd like to tell my users when they're off-line how many pending changes they have (or if they have pending changes at all for that matter). Is there any way to query the provider or orchistrator to get statistics for pending changes?

    Thanks in advance,


    Friday, September 10, 2010 8:56 PM

All replies

  • do a sync and suscribe to the ChangesSelected event, the event args will have the SyncContext which contains the change dataset. If you dont want to sync, simply raise an exception in the event to cancel the sync.
    • Proposed as answer by Janadh0101 Tuesday, June 19, 2012 7:48 AM
    Friday, September 10, 2010 11:56 PM
  • Thanks June, I'll try that!
    Monday, September 13, 2010 9:43 PM
  • You are trying to Get the source changes that are not contained in the destination knowledge....if so,

    If you have the destination knowledge & the source knowledge you can try to get the changes explicitly. For an example, see the Sync101NoMDS sample. See the SyncProvider.GetChangeBatch implementation. This will give you the code that checks to see if the source item is contained within the destination knowledge. you can use this to GetTheChanges (you can do this outside of the framework handshakes)

    Tuesday, September 14, 2010 12:27 AM