Opening expanded source files
Use the Show Expanded Source menu item to open a COBOL or PL/I file in read-only mode with copybooks and include files expanded.
- COBOL Editor
- PL/I Editor
- z Systems LPEX Editor
Before you begin
- Associate a property group with the file. Specify these property group options:
- In the SYSLIB field of the property group, specify a search path for copybooks and include files.
- On the Local Preprocessors page, select -INC/++INCLUDE Preprocessor.
- In the Preprocessor arguments field, specify CMT(ON).
- If you previously ran the local include preprocessor against the source file, open the file in an editor and select (COBOL and PL/I Editors) or (z Systems LPEX Editor).
About this task
The Show Expanded Source action uses the local include preprocessor that is included with the product to open a source file with copybooks and include files expanded. The preprocessor runs in the background so that you can continue to use the product while the Show Expanded Source action completes. The expanded file is opened in the same editor from which you requested the action. If, for example, the file was open in the COBOL Editor when you requested the Show Expanded Source action, then the expanded file is also opened in read-only mode in the COBOL Editor. While the expanded file is open, you can do any actions that are valid for files open in read-only mode.
Procedure
- Open a COBOL or PL/I source file.
- From the menu, select or press Ctrl+Shift+E.
Results
* COPY ABC.
* Copybook Location:
* MYSYSTEM\HLQ\HLQ.A001.COPYLIB1.COPYLIB\MYCOPY1.cpy
01 XYZ PIC X
01 FIRST PIC 9/*
%INCLUDE MYINC1;
* Include Location:
* MYSYSTEM\HLQ\HLQ.A001.PLILIB1.INCLUDE\MYINC1.inc
*/
dcl XMYINC1 CHAR(20) INIT('INSIDE MYINC1');