<PARM> [ HP DeskManager Customization ] MPE/iX 5.0 Documentation
HP DeskManager Customization
<PARM>
Syntax
<PARM {index} [varname] >
where:
index numeric value in the range 1 to 9
varname unquoted string
Description
<PARM> returns the parameter which was entered on the script command line
in the position specified by index. The index parameter does not
represent a character count. The varname parameter represents an
unquoted string variable and if present, <PARM> will return the index the
element within varname. Although varname is a variable, it should not be
enclosed in a <VAR> sequence. HP Desk is limited to parsing up to nine
parameters from a script command line or nine elements from a variable.
If it is required that more than nine parameters or elements be parsed,
it will be necessary to make use of the <PARMREM> function to "shift"
elements from right to left.
See also: <PARMPRES>, <PARMREM>, <PARMTYPE>.
Example
&SAVE var1 <PARM 1>
This saves the first parameter given in the script command line in a
variable called var1.
The following commands will print parameter 10 from the script command
line:
&SAVE var2 <PARMREM 9>
&PRINT <PARM 2 var2>
This gets around the fact that only the numbers 1 to 9 can be used with
the <PARM> command. It prints the second parameter of variable var2,
which is equivalent to parameter 10.
MPE/iX 5.0 Documentation