The VARINF macro can be used to analyze complex variables whose elements are themselves complex variables.
Operation | Operands |
VARINF | MF = E |
MF = D ,PREFIX = V / prefix | |
MF = C ,PREFIX = V / prefix ,MACID = ARI / macid | |
MF = L ,NAMLEN = <integer 1..255> ,NAMADR = <name 1..8> ,SCOPE = *VISIBLE / *TASKONLY ,POSIT = *CURRENT / *UP / *DOWN / *NEXT ,MAXLEN = <integer 1..4096> ,RESADR = <name 1..8> |
Operands
MF = E
Execute format of the macro call: generates an SVC.
PARAM
Designates the address of the operand list that is evaluated for the macro call (address of macro call with MF = L).
= <name 1..8>
Designates the symbolic address of the operand list.
= (<integer 1..15>)
Designates the register that contains the address of the operand list.
MF = D
DSECT format of the macro call: generates a DSECT for the operand list. The names generated begin with the string VARINF; they can be modified with PREFIX.
PREFIX = V / prefix
Defines the first character of the generated names.
Default: the generated names begin with the letter V.
MF = C
C format of the macro call: generates an operand list whose symbolic names begin with the string VARI. They can be changed with PREFIX and MACID.
PREFIX = V / prefix
Defines the first character of the generated names.
Default: the generated names begin with the letter V.
MACID = ARI / macid
A string of up to three characters that replaces characters 2 to 4 of the generated names. Default: ARI
MF = L
LIST format of the macro call: generates the operand list for the macro call with MF = E (Execute format); the macro call must be addressable by means of a symbolic address.
NAMLEN = <integer 1..255>
Designates the length of the variable name.
NAMADR = <name 1..8>
Designates the symbolic name of the variable name address from which the element names can be queried.
SCOPE
Designates the scope of the variable.
= *VISIBLE
The variable is a procedure-local variable.
= *TASKONLY
The variable is a task-global variable.
POSIT
Determines the variable element whose name is to be returned. Positioning is relative rather than absolute, based on the variable element that was last accessed.
= *CURRENT
Returns the name of the current variable element, i.e. of the variable element that serves as a starting point for positioning (existence check).
= *UP
Returns the name of the complex variable to which the current variable element belongs.
= *DOWN
If the current variable element is itself a complex variable, POSITION=DOWN returns the name of the first element of this complex variable.
= *NEXT
Returns the name of the next complex variable on the same level.
MAXLEN = <integer 1..4096>
Designates the maximum length of the field in which the variable name is returned.
RESADR = <string 1..8>
Symbolic address of the field in which the variable name is returned.
The following output fields will be found in the operand list after the call:
<PR> = <prefix><macid> <PR>VALL : length of the result name <PR>VTYP : Variable type: Possible values: <PR>VANY: *ANY <PR>VSTR: *STRING <PR>VINT: *INTEGER <PR>VBOO: *BOOLEAN <PR>VSTU: *STRUCTURE <PR>MULT : MULTIPLE-ELEMENTS: Possible values: <PR>MNO: *NONE <PR>MARR: *ARRAY <PR>MLIS: *LIST <PR>SINF : STRUCTURE INFORMATION (relevant if: <PR>VTYP=<PR>VSTU) Possible values: <PR>SDYN: *DYNAMIC <PR>SCMD: *BY-SYSCMD <PR>SLAY: LAYOUT
Return codes
The table below lists the return codes in hexadecimal notation.
Subcode2 | Subcode1 | Maincode | Meaning |
00 | 00 | 0000 | Macro call was successful; no error |
00 | 01 | 0001 | Parameter error |
00 | 01 | 0002 | Syntax error in variable name |
00 | 40 | 0003 | Area too small |
00 | 40 | 0004 | Variable not declared |
00 | 40 | 0005 | Variable container not available |
00 | 40 | 0007 | Last variable element was reached; no further variable elements present |
00 | 01 | FFFF | Unknown unit or function number |
00 | 02 | FFFF | Function not available |
00 | 03 | FFFF | Wrong version of operand list |