Information About Distributing your SprintDB Pro Applications The simplest method of distributiong your applications is outlined below:
- Copy the database file (*.cdb) to any folder on the user's Pocket PC.
- Copy form files (*.RAF) to the \Program Files\SprintDB Pro\Forms directory.
You can of course, create a ZIP file that includes a README.TXT file, informing your users to do the above. - or create a stand-alone installation .exe that does it automatically. But please keep in mind that the
user is able to define a different "Forms Folder" if they so desire. Auto-Running Applications To have your applications run automatically when you tap the database name, select AutoRun from the Form > Properties > Basic
tab and choose "Yes". If you would like to run a SprintDB Pro
application from the Windows CE desktop or Start Menu, set AutoRun to "Yes" and create a shortcut to the .cdb file. You may also like to have your application run when your device is turned on. To do this; create a shortcut, and copy it into the into the \Windows\StartUp folder.
Refer to your Windows CE 3.0 or Windows 2002 User Manual for more information about adding programs to the Start Menu or StartUp folder. Setting an Application Password To protect your applications, you should set a Password.
This prevents other users from accessing or modifying your code.The password property is on the Form > Properties
menu. Make sure to record your password somewhere safe, otherwise you won't be able to access your code.
Setting and Using Local Variables SprintDB Pro
allows you to declare and use Local Variables. These can only be used within a particular Macro.To declare a Variable name, use the DIM statement in the following form: Dim State FullName To use the variable, use the SetVar
statement in the following form: SetVar @StateFullName
Setting and Using Global Variables SprintDB Pro
allows you to use up to 10 Global Variables: Gvar0 - Gvar9. To set a Global Variable, use the SetVar method. The following code snippet uses both Local and Global variables.
Dim Location Dim State Dim Zipcode Dim State FullName SetVar @Location, @Gvar9 SetVar @State, @Gvar8 SetVar @Zipcode, @Gvar7
SetVar @StateFullName, DLOOKUP( States1.FullName, States1, States1.State = @State ) If @StateFullName =NULL SetVar @StateFullName, @State EndIf
SetVar @Gvar9, @Location + ' ' + @StateFullName + ' ' + @Zipcode Calling Forms SprintDB Pro allows you to use CallForm to call a either a separate independent Form
or a SubForm. The syntax is:CallForm [FormName] Copying Data to the Clipboard There are two ways to copy data to the system clipboard and run-time. The first method is to 'Tap and hold' the stylus on the required field and select Copy
from the pop-up menu. The second method uses the SetClipboard action, for example, in a the code for a Button called "CopyText": SetControl, [ControlName].SetClipboard
The data will now be available to paste into other applications. Using SetFocus This is a very useful method, particularly from the point of view of usability. Use SetFocus
to move the cursor to the field you want the user to interact with.Method: SetFocus, [ControlName] |