CGETPARM: Program subroutine called by the destination program to create the GETPARM screen. Variation of GETPARM with reduced arguments required.
EZGETPRM uses a screen-oriented form, similar to EZFORMAT and EZFORMC. Note that the screen files produced by EZGETPRM are not usable by any other program.
As with any other approach to GETPARMs, you must select the type, PF keys enabled, message lines, Parameter Reference names, and keywords. EZGETPRM prompts for most of these, but assumes that you are aware of the requirements for message field attributes and other items.
EZGETPRM will extract the keywords from other text on the screen by looking for eight-character names followed by a space, the equals sign, another space, and an alphanumeric string of the length required by the field. The first character in the field area determines the requirements for the field; valid entries are 'C' (all characters), 'U' (uppercase characters only), 'A' (alphanumeric characters), 'N' (numeric), 'I' (positive integer), and 'H' (hexadecimal).
When completed, the screen file is processed and COBOL or BASIC statements are generated. At the conclusion of the session you may save the screen file, the generated source code, or both.
OPTIONS Press PF(02) to generate a new GETPARM screen, PF(03) to reuse an old screen file, or PF(16) to exit the program.OPTIONS2 Press PF(02) to save generated source, PF(03) to save the screen file, PF(04) to save both, or PF(16) to exit the program.
COBCOPY Enter data and press (RETURN) to continue.
FILE (blank) The location of the COBOL or BASIC LIBRARY [outlib] source to be generated. VOLUME [outvol]
SAVE Enter data and press (RETURN) to continue.
FILE (blank) The location of the screen file LIBRARY [uid]+SAVE generated by the program. The VOLUME [outvol] library name defaults to the user ID plus SAVE
To create GETPARM code, run the utility and specify the general parameters. These options include the message ID, PRNAME, type of GETPARM, display option, form, and the PF keys allowed. When this information is complete, press (RETURN) to enter the screen information.
As described on the documentation screen (PF(01) from the OPTIONS menu), the first two lines on the input screen should be used for text to appear above the keywords. The last text line must be followed by a blank line, then all of the keywords to be created. The keywords are formatted with an eight-character name, a space, an equals sign, a space, and a text field of the length desired. The text field must begin with a letter indicating what type of field it will be (see descriptions, above). Some examples:
'INFILE = UXXXXXXX' Keyword: INFILE. An eight-character field; accepts only upper-case elements.'HEXFIELD = HX' Keyword: HEXFIELD. A one-byte field (two hex digits).
'BADPRM =XX' Invalid format. Improper spacing around the keyword and equals signs, and an invalid start character on the string.
See the GETPARM program (not the subroutine) for help in understanding the options available in creating GETPARM screens.