SetSyncRegistryProperties

Description

Sets synchronization properties in the local machine registry.

Applies to

MLSynchronization, MLSync controls

Syntax

SyncObject.SetSyncRegistryProperties ( )

Argument

Description

syncObject

The name of the synchronization object.


Return value

Integer.

Returns 1 for success and -1 for failure.

Usage

If necessary, the SetSyncRegistryProperties function can create a key in the Windows registry from the value of the SyncRegistryKey property of the synchronization object. Failure occurs if the SyncRegistryKey property is not set in the synchronization object.

Examples

The MLSync object generated by the MobiLink wizard for SQL Anywhere uses the following code in its Constructor event:

IF d_Registry_Build < d_this_object_build THEN      
// First time deployment of new revision - set 
//"ObjectRevision" to this revision of the wizard       
// objects and override all registry values   
   rc = this.SetSyncRegistryProperties()
ELSE
   rc = this.GetSyncRegistryProperties()
END IF      

This code sets the values of authentication properties in the Windows registry when the build number of the running application is higher than the build number in the registry (or when the build number in the registry cannot be found).

See also

GetCommandString

GetSyncRegistryProperties

SetParm