Previous Topic: CALLNext Topic: GOBACK


DEFINE

Purpose

Establishes an entry point for a subroutine and to define the subroutine processing. At runtime, a subroutine is executed when it is named in a CALL statement.

Syntax

                                                 ┌───────────────────────┐
►►─── DEFINE subroutine subroutine-name ─── . ───▼─ command statement. ──┴────►◄

Parameters

subroutine-name

Specifies the 1- to 8-character name of the subroutine being defined.

Subroutine-name must be unique within the process.

command-statement

Specifies the process commands that define the subroutine.

Command-statement can be any process command statement except DEFINE SUBROUTINE.

Usage

Considerations