Steps in Developing ActiveSync Providers
A version of this page is also available for
4/8/2010
The following steps are a recommended sequence for designing and coding ActiveSync providers. All these steps are necessary, regardless of the order in which you perform them.
- Define the types of objects you want to synchronize.
Object names should have a mnemonic relation to the object. If a name collides with an existing ActiveSync provider name, the existing service provider will be replaced.
It is usually a good idea to write a single ActiveSync provider to synchronize similar objects, or types that reside in the same store. For example, one ActiveSync provider synchronizes Appointment, Contact, Task, and Message object types. - Specify an object ID for objects in each object type, preferably as an integer or as a string.
If you are not using a GUID, select the algorithm that will be used to create the ID. - Decide how objects of each object type are to be enumerated.
You need to establish the order-of-creation sequence. - Establish how to determine whether an object has changed.
A time stamp of the last modification is typically used. A number incremented each time an object is changed can also be used. - Define the HREPLITEM and HREPLFLD structures.
HREPLITEM is usually cast into a structure that contains the object ID, timestamp, and any other object-specific data. HREPLFLD is usually cast into a different structure that contains the conversion filter for the object type. - Define a unique ProgID for the store.
For example, MS.WinCE.Outlook. - Obtain a GUID for the store.
- Implement the device functions and desktop interface methods.
- Read ActiveSync Programming FAQ to make sure all points have been taken into account.
- Compile, configure and test the ActiveSync service provider.