ISyncMgrSynchronize::PrepareForSync method (mobsync.h)
Allows a registered application to display any user interface, and perform any necessary initialization before the ISyncMgrSynchronize::Synchronize method is called. For example, an application such as the Microsoft Outlook email client may need to display the password dialog box to enable a user to log on to a mail server.
HRESULT PrepareForSync( ULONG cbNumItems, GUID *pItemIDs, HWND hWndParent, DWORD dwReserved );
The number of items in the array pointed to by pItemIDs.
An array of item IDs that a user chooses to synchronize.
A handle to the parent HWND that a registered application should use for any user interface element displayed. This value may be NULL.
Reserved. Registered applications should ignore this value.
This method supports the standard return values E_INVALIDARG, E_UNEXPECTED, and E_OUTOFMEMORY, and the following:
||Preparation is successful.|
A registered application handler should return from this method as soon as possible, and then call the PrepareForSyncCompleted method. A registered application handler can call the PrepareForSyncCompleted method before returning from this method.
Registered applications should only show a user interface if the SYNCMGRFLAG_MAYBOTHERUSER flag is set in the dwSyncFlags parameter of the ISyncMgrSynchronize::Initialize method. If a registered application cannot prepare for synchronization without showing a user interface when the SYNCMGRFLAG_MAYBOTHERUSER flag is not set, it should return S_FALSE from this method.
The array of item IDs that are passed into this method are relevant to the ISyncMgrSynchronize::Synchronize method also.
The ISyncMgrSynchronizeCallback methods can be called on any thread in a registered application.
|Minimum supported client||Windows 2000 Professional [desktop apps only]|
|Minimum supported server||Windows 2000 Server [desktop apps only]|