PURPOSE: The USE CM command executes the specified Command Module (CM).
USE CM name [IN DBL dbl_name] [RESTART AT line_number]
[PRESERVE TEXT]
USE NO CM
USE CM name |
begins executing the named CM and sets the name of the CM to @CM_NAME. CM's can be executed within a CM allowing next CM's |
[IN DBL dbl_name] |
used to invoke a CM in a Data Base Library (DBL) other than the current one. |
RESTART AT line_number |
causes execution to begin at the specified line. The value given must be an existing line number. This clause cannot be used in a USE CM command that is within a CM. |
PRESERVE TEXT |
prevents the text returned by @COMMAND_TEXT function from being cleared by a subsequent USE CM or USE PM command line used to invoke an equated command and can be parsed and used in the equated CM or Process Module (PM). |
USE NO CM |
causes ACCENT R to exit all nested USE CM commands and return to command level. It also clears @CM_NAME. EXIT CM |
*USE CM QUICK_REP<CR>
*USE CM YTD_SALES_DBM2 RESTART AT 170<CR>
NOTES: Restarting the CM any place but at the beginning requires that conditions be properly established beforehand; e.g., USE DS if required, values set to system fields or Global Storage (GS) field, etc. This feature should only be used as a debugging tool or to restart after an error. CM’s may be nested to 10 levels.
SEE ALSO: Command Module, EQUATE command, @COMMAND_TEXT System Functions