When ordering parameters within commands, place the parameters that identify the object being operated on, first. For example, on a ‘Create Library List Object’ command, place the identifier of the library list first. Often, this will be a key parameter (KEYPARM(*YES)).
Always place required parameters before the other parameters. Do not use numeric reordering of prompting if the parameter has a value other than MIN(0), as allowed for the PROMPT keyword on command definition statements. Doing so gives undesirable results when using the command prompter with positionally specified parameters.
Place the parameters, whose values are most likely to be changed by the user, before the other parameters.
Use the MAXPOS keyword on the OS/400 Create Command (CRTCMD) command if you know or suspect that it will be necessary to add additional parameters at a later date, and that the new parameters will need to be inserted in a position before one of the existing parameters. In any case, specify MAXPOS for all commands with a lot of parameters.
Place any ‘Element definition’ (ELEM) and ‘Qualifier definition’ (QUAL) statements to define command parameters that are lists, immediately after the first PARM statement they describe. This facilitates the copying of code from one member to another. For IBM i commands, PMTCTL statements should also be placed adjacent to the PARM statement they control.

|
Copyright © 2014 CA.
All rights reserved.
|
|