z/OS ISPF Edit and Edit Macros
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


XSTATUS—Set or Query Exclude Status of a Line

z/OS ISPF Edit and Edit Macros
SC19-3621-00

The XSTATUS assignment statement either sets the exclude status of the specified data line, or retrieves the exclude status of the specified data line and places it in a variable.

Syntax

Read syntax diagramSkip visual syntax diagram
Assignment statement syntax

>>-ISREDIT--(varname)-- = --XSTATUS--+-linenum-+---------------><
                                     '-label---'   

Read syntax diagramSkip visual syntax diagram
>>-ISREDIT--XSTATUS--+-linenum-+-- = --+-X--+------------------><
                     '-label---'       '-NX-'   

varname
The name of a variable to contain the exclude status, either X or NX.
linenum
A relative line number identifying the line.
label
A label identifying the line.
X
Specifies that the specified line is to be excluded.
NX
Specifies that the specified line is to be shown (non-excluded).

Description

Exclude status determines whether the line is excluded.

If you want to exclude several lines at one time, the EXCLUDE command should be used. Similarly, to show several lines at one time, use the FIND command.

Return codes

0
Normal completion
8
An attempt to set a line status to NX could not be performed. The line has a pending line command on it. For example, if an excluded line contains an M line command in the line command field, then the MOVE/COPY IS PENDING message is displayed and the lines cannot be shown. The reset command can be used to remove your line commands from the line command field.
12
Line number is not an existing line.
20
Severe error

Examples

Use XSTATUS together with SEEK and CHANGE to preserve the exclude status of a line. For example, to store the exclude status of the line whose number is in variable &N in variable &LINEX:
ISREDIT (LINEX) = XSTATUS &N
To exclude line 1:
ISREDIT XSTATUS 1 = X
To locate a string and change it, saving and then restoring the exclude status:
ISREDIT SEEK &DATA
IF &LASTCC = 0 THEN -
  DO
    ISREDIT (XLINE) = XSTATUS .ZCSR
    ISREDIT CHANGE &DATA &NEWDATA .aZCSR .ZCSR
    ISREDIT XSTATUS .ZCSR = (XLINE)
  END

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014