This is a Mainframe COBOL forum - you can post your queries on Mainframe COBOL, VS COBOL II, COBOL/370 , Enterprise COBOL
Moderators: dbzTHEdinosauer, Moderator Group
Joined: Tue May 05, 2015 8:21 pm
Hi I was wondering if there is a way to put a paragraph name into a variable. There has to be a better way than how I am doing it. Right now Im doing MOVE "1000-PARAGRAPH-NAME" TO WS-HOLD-NAME.
I want avoid having to move 1000-PARAGRAPH-NAME, and have it done automatically. Like this:
01 WS-HOLD-NAME PIC X(30).
Perform some function to get the paragraph name and store it to WS-HOLD-NAME
DISPLAY 'Paragraph name is ' WS-HOLD-NAME
OUPUT SHOULD BE
Paragraph name is 1000-PARAGRAPH-NAME
Free tutorials from mainframegurukul
JCL Tutorial Covers all important JCL concepts.
Cobol Tutorial This tutorials covers all Cobol Topics from STRING to COMP-3.
DB2 Tutorial DB2 Tutorial focuses on DB2 COBOL Programming.
SORT Tutorial This Tutorial covers all important aspects of DFSORT with examples
CICS Tutorial This CICS tutorial covers CICS concepts and CICS Basics, CICS COBOL Programming.
Mainframe Interview questions
Mainframe Tools and others