Previous Topic: ARG

Next Topic: DO


CALL

The CALL instruction is supported, including the CALL ON/OFF condition support. In addition, NetMaster REXX has an extension for a standard CALL.

If the name of the program being called is specified in parentheses, then the name is treated as a simple variable. The actual program name is the value of that variable. This design allows you to eliminate many uses of the INTERPRET instruction.

For example, in REXX, to call a program that is dynamically named:

PROGRAM = <some name>
INTERPRET 'CALL 'PROGRAM' arg,arg,…'

In NetMaster REXX, you can code instead:

PROGRAM = <some name>
CALL (PROGRAM) arg, arg, …