Previous Topic: Define the OPSLINK Routine in PL/1 Programs

Next Topic: Define an Output Array in COBOL Programs

Call OPSLINK from COBOL Programs

The arguments passed to OPSLINK are either text strings or integer values. All text strings passed should be defined in the calling programs as follows:

DATA DIVISION.
01 ARGSTR.
   03 STRING-LENGTH   PIC 9(4) COMP VALUE 0.
   03 STRING-TEXT     PIC X(256) VALUE SPACES.

The STRING-LENGTH should be set to the number of significant characters in STRING-TEXT. Zero indicates a null string.

All integers passed should be defined in the calling program as:

DATA DIVISION.
01 ARGINT             PIC 9(8) COMP.

Important! Failure to observe these definition requirements may result in obscure storage overlay problems, S0Cx type abends, or both.