You can run production
synchronizations by customizing their behavior by creating a PFF file. You then use the PFF as a command line parameter for DataManager.exe (the associated filename of this utility). For example, suppose you've named your Sync PFF
Download Data.pff; you can then run the synchronization by invoking this file from the command line:
"C:\Program Files (x86)\CSPro 8.1\DataManager.exe" "Download Data.pff"
This assumes that CSPro was installed in the default directory. PFF files always have a .pff extension. Note that you can only sync .csdb(e) files—data files stored as text cannot be synced.
You can create a PFF file in one of two ways: either [1] create one with a text editor (such as Notepad or Wordpad), or [2] let it be generated automatically for you by downloading a data file from
CSWeb,
Dropbox, or another
synchronization service. You can also manipulate PFF files in logic by using the
Pff object.
The following section shows the options available to you in a synchronization PFF file. A PFF file is not case sensitive, so you can use any combination of upper and lower case text.
[Run Information]
Version=CSPro 8.1
AppType=Sync
[ExternalFiles]
MY_DICT=.\MyData.dat
[Parameters]
SyncService=https://example.org/csweb/api
SyncDirection=Get
Silent=Yes
The [Run Information] block is required and must appear exactly as shown in the example above.
The
[ExternalFiles] block is required. It relates the dictionary name to the data file that will be synced. If the data file does not exist, it will be created. A copy of the dictionary must exist on the
synchronization service (which it automatically will if using CSWeb).
- SyncService= specifies the connection string identifying the type or URL of a synchronization service.
- SyncDirection= specifies the direction of the synchronization. The three options, Get, Put, Both, are detailed in the help documentation for the syncdata function.
- Silent= determines whether or not to close Data Manager automatically after the synchronization completes. The value can be Yes or No; it will default to No if this parameter is not listed.