Pathway/iTS SCREEN COBOL Reference Manual (G06.24+, H06.03+, Pathway/iTS 1.0+)
Data Division
Compaq NonStop™ Pathway/iTS SCREEN COBOL Reference Manual—426750-001
5-62
PICTURE and TO/FROM/USING Restrictions
In the following example either of the paired Message Section and Working-Storage
Section data structures is acceptable.
WORKING-STORAGE SECTION.
01 WS-MSG
05 WS-A PIC X
05 WS-B PIC X
05 WS-C PIC X
05 WS-D PIC X
MESSAGE SECTION.
01 MS-MSG
05 MS-A PIC X FROM WS-A
05 MS-B PIC X FROM WS-B
05 FILLER PIC X
05 MS-C PIC X FROM WS-C
05 MS-D PIC X FROM WS-D
WORKING-STORAGE SECTION.
01 WS-MSG
05 WS-A PIC X
05 WS-B PIC X
05 FILLER PIC X
05 WS-C PIC X
05 WS-D PIC X
MESSAGE SECTION.
01 MS-MSG
05 MS-A PIC X FROM WS-A
05 MS-B PIC X FROM WS-B
05 FILLER PIC X
05 MS-C PIC X FROM WS-C
05 MS-D PIC X FROM WS-D
PICTURE and TO/FROM/USING Restrictions
A single-field message must have a PICTURE clause and a TO, FROM, or USING
clause. For example:
WORKING-STORAGE SECTION.
01 WS-MSG PIC X(10).
MESSAGE SECTION.
01 MSG PIC X(10) USING WS-MSG.
When there are multiple fields within a message, the following rules apply:
•
The 01 level item cannot have a PICTURE clause or a TO, FROM, or USING
clause.
•
The group level item cannot have a PICTURE clause or a TO, FROM, or USING
clause.