Passing Parameters to an Application

The parameters to be passed to your application must be the last parameters entered on the command line.

When you invoke an application shell, Uniface searches the information on the command line from left to right, looking for command line switches.

The first parameter found that is not recognized as a switch or sub-switch, is assumed to be the name of the application shell. Any parameters that follow are placed in general variables, starting with $1, $2, and so on, so they are available to the application for processing. For example:

uniface /asn=myasn /pri=63 myappl name password

Instead of specifying the name of the application shell on the uniface command line, you can copy the uniface executable and rename it to the same name as your application shell. You can then invoke the copy with just the Uniface switches and application parameters. For example:

myappl /asn=myasn /pri=63 name password

Note:  You cannot pass parameters to the Uniface IDE using the command line, because it assumes that any unidentified information is to be a component name and tries to compile it.

Wherever a DateTime parameter is specified, it must have the following format:

dd-mm-yyyy:hh:nn:ss

All the separators are optional; all the digits must be present.

Related Topics