RunSync

Description

Launches the MobiLink DBMLSync.exe process and waits for it to complete.

Syntax

RunSync ( exename, publication, mluser, mlpassword, connectstring, otherparams, windowclassname)

Argument

Description

exename

A read-only string (passed by reference) that defines the location of the MobiLink synchronization client DBMLSync.exe file

publication

A read-only string for the name of the publication or the names of the publications you want to synchronize on the remote and consolidated databases

mluser

A read-only string for the MobiLink user name

mlpassword

A read-only string for the MobiLink password

connectstring

A read-only string for the remote database connection parameters or for the location of the DSN file containing the connection parameters

otherparams

A read-only string for any logging, command line, and extended options that you want to use with the DBMLSync process

windowclassname

A read-only string for the handle to the window that you want to have receive messages from the dbmlsync process

Returns

Long. Returns 1 for success and -1 if another instance of the synchronization client is currently running. DBMLSync.exe process errors return positive error codes.

Usage

You can use the RunSync function to start the DBMLSync process. If you use the MobiLink Synchronization for ASA wizard, it is not necessary to make this call explicitly. This is because the uf_runsync function of the wizard-generated user object makes an equivalent call to pb_run_dbmlsync in the PocketBuilder VM, using parameters based on instance variables generated by the wizard, selected by the end user, or obtained from the device registry.

The MobiLink Synchronization Reference describes permitted values for the otherparams argument. These values are also selectable in the MobiLink Synchronization for ASA wizard.

See also

CancelSync