Version 4.2.6 for Mainframes
 —  Parameter Reference  —

CV - Attribute Control Variable

This session parameter is used to reference an attribute control variable. An attribute control variable is defined with Format C (see Special Formats in the Programming Guide) and is used to

Possible settings B, C, D, I, N, U, V Field representation attributes (see session parameter AD).
P Field protection (see session parameter AD).
BL, GR, NE, PI, RE, TU, YE Color (for an explanation of the color codes, see the session parameter CD).
Default setting none
Applicable statements:

DISPLAY
INPUT
PRINT
PROCESS PAGE
WRITE

Parameter may be specified at statement level and/or at element level.
Applicable command: none

Example:

DEFINE DATA LOCAL 
1 #ATTR(C) 
1 #A   (N5) 
END-DEFINE 
... 
MOVE (AD=I CD=RE) TO #ATTR 
INPUT #A (CV=#ATTR) 
   ...

By specifying the MODIFIED option of the IF statement, the attribute control variable can be used to check whether the contents of a field has been modified during the execution of an INPUT or PROCESS PAGE statement:

IF #ATTR MODIFIED ...

A single attribute control variable can be applied to several input fields by specifying it once at statement level or multiple times at element level, in which case the "modified" status indication is set if any of the fields referencing the control variable has been modified. If the CV parameter is specified both at statement level and at field level and the attribute control variable for the individual field is empty, the attribute control variable for the statement will be used for the field.

The attribute control variable can be expanded up to three dimensions, for example, CONTR(*), CONTR(*,*), CONTR(*,*,*), depending on the rank of the corresponding array.

Top of page