You are here: Automating Analyzer > Running Procedures > Executing Other Procedures from Within a Procedure

Executing Other Procedures from Within a Procedure

You can issue a procedure from within a procedure using the Do command. In practice, Do operates much like a sub-routine call in traditional programming.

For example, a procedure called “Month_End” contains the following commands:

DO PROCEDURE_A

DO PROCEDURE_B

DO PROCEDURE_C

When Month_end is running, it first executes the commands stored in PROCEDURE_A. Once PROCEDURE_A has terminated, processing returns to Month_end and PROCEDURE_B is executed. Similarly, PROCEDURE_C is executed after PROCEDURE_B has terminated. In this way, you can include sets of standard commands in your procedures whenever required. Called procedures can, in turn, call other procedures as well.

When procedures are called in this manner, it is possible to conditionally or repeatedly call a procedure.

For more information, see Do command.