Directives

DEF CTL/ERR/LFO/LFA/LPG/HWD/NID

Define System Variables

Formats

1. Set Contents of CTL Variable:

DEF CTL=num

2. Set Contents of ERR Variable:

DEF ERR=num

3. Set Contents of LFO Variable:

DEF LFO=num

4. Set Contents of LFA Variable:

DEF LFA=num

5. Set Contents of LPG Variable:

DEF LPG=str

6. Set Contents of HWD Variable:

DEF HWD=str

7. Set Contents of NID Variable:

DEF NID=str

Where:

num

Value for setting selected variable. Numeric expression, integer.

str

Value for setting selected variable. String.

Description

Use these DEF formats to define the contents of a specified system variable:

Numeric Variables:

 

DEF CTL

Numeric code (integer) that represents a signal of user input from the keyboard or mouse.

 

DEF ERR

Numeric value (integer) that indicates the last system-detected error.

 

DEF LFO

Channel/file number of the last file opened.

 

DEF LFA

Channel/file number of the last file or device accessed.

String Variables:

 

DEF LPG

Lead program to run (normally passed in the Command line or START directive).

 

DEF HWD

Current directory when process started.

 

DEF NID

Network identifier for the processor running the application.

(The DEF CTL/ERR/LFO/LFA directives were added in PxPlus v7.00.)
(The DEF LPG/HWD directives were added in PxPlus v8.11, build 9182.)
(The DEF NID directive was added in PxPlus v8.30, build 9190.)

See Also

CTL Control Code: Key to End Input
ERR Last System-Detected Error Value
LFO Last File Number Opened
LFA Last File Number Accessed
LPG Lead Program Name
HWD Starting/Home Directory
NID Network or Network Node ID