Using the UltraLite Synchronization wizard

About the wizard

The UltraLite Synchronization wizard generates objects that make it easier for you to initiate and control MobiLink synchronization requests from an application connection to a remote UltraLite database. Some of the objects created by the wizard are similar to the objects created by the MobiLink Synchronization for ASA wizard, although there are differences in the way MobiLink synchronizes remote SQL Anywhere and remote UltraLite databases.

One of the major differences is that there are no subscriptions in an UltraLite database. Another difference is that the MobiLink synchronization call is made directly on the connection object to the remote UltraLite database, rather than through an outside call to a separate synchronization utility.

Information required by the wizard

Table 16-9 shows the information required by the UltraLite Synchronization wizard. For information about preparing databases for synchronization, see the chapter on MobiLink synchronization in the Resource Guide.

Table 16-9: Information required by UltraLite Synchronization wizard

Option

Description

Application Library

PKL where the objects created by the wizard are stored

Publications

List of comma separated publications you want to synchronize

Script Version

The version of the script you want to use for synchronization. If you have not created scripts for synchronization events, you can leave this blank and check the Send Column Names box.

Send Column Names

Optional check box that is useful for testing if you have not created your own scripts for synchronization events

Communications Stream

Select the communications stream type that you want to use. ActiveSync is not supported as a communications stream type for synchronization from a PocketBuilder application

Host

Specify the numeric IP address for the MobiLink server. If you leave this blank, localhost is used as the server name. The IP address should be entered as a list of four sets of two or three digit numbers separated by periods, such as 199.99.001.01

Port

Specify a port for the MobiLink server. If you leave this blank, 2439 is used as the default port

Additional

Additional parameters can be added for the MobiLink server connection in the format:

keyword=value[;keyword=value...]

Authentication Parameters

Specify a comma separated list of parameters that you want to pass for authentication purposes to the MobiLink server. PocketBuilder parses the list of parameters you enter, counts them, and passes them as an array in a structure created by the UltraLite Synchronization wizard

Names for the objects

You can specify names for the objects created by the wizard if you do not want to use the default names provided by PocketBuilder

Override Previous Synchronization Settings

Select this check box and assign a build number to the objects generated by the wizard to enable runtime overrides to client registry settings for MobiLink parameters entered by a user

Build Number

Specify a positive numeric value for the build number. To override the registry settings, the build number you assign must be higher than the build number in the registry, if there is one.

What the wizard generates

The UltraLite Synchronization wizard creates a nonvisual user object, a global external function, and three different structure objects for passing parameters, all of which make it easier to add database synchronization capabilities to your PocketBuilder target. By default, the wizard also adds a second global external function and two optional display windows.

Table 16-7 shows objects that can be generated by the wizard, listed by their default names, where appname stands for the name of the current application.

Table 16-10: Objects generated by UltraLite Synchronization wizard

Default name

Description

nvo_appname_ulsync

Nonvisual user object that starts synchronization from the remote client

gf_appname_ulsync

Global function that instantiates nvo_appname_ulsync to start the synchronization.This function includes the logic to start the synchronization with or without a feedback window

s_appname_ulsync_parms

Structure used to store runtime information, such as connection parameters entered by the user in the w_appname_ulsync_options window

s_appname_ulsync_info

Structure used in the Synchronize call to pass values of instance variables set in the nvo_appname_ulsync nonvisual user object

s_appname_ulsync_results

Structure used to hold summary information from the synchronization process that is returned in the GetSynchronizeResult call

w_appname_ulsync or w_ulsync_default_feedback

Optional feedback window that can be used, instead of the standard MobiLink status window, to display synchronization status to the client. Even if you do not use the optional status window, a generated feedback window must be instantiated by the gf_appname_ulsync function

w_appname_ulsync_options

Optional window that allows the application user to change MobiLink connection arguments at runtime

gf_appname_configure_ulsync

Optional global function that calls the w_appname_ulsync_options window