You can create new COBOL programs from a template.
Before you begin
To specify the program location on a partitioned data set
or a sequential data set, you must have an existing MVS™ subproject.
About this task
For more information about modifying the program template,
see Setting preferences for COBOL code templates.
For more information about COBOL templates, see Bidirectional COBOL templates.
Procedure
To create a new COBOL program from a template, complete
the following steps:
- Click .
You can also
use the Ctrl+N key combination.
- Expand the COBOL category.
- Select COBOL Program.
- Click Next.
- In the New COBOL Program panel, complete
the following steps:
- Specify the program name.
- Specify the author of the program.
- Specify the program location.
The options
are as follows:
- Partitioned Data Set
- Specify the following parameters:
- Remote location
- Host code page
- Data set name
- Member
- Allocate PDS if new
You can specify the data set characteristics in the next wizard
panel.
- Sequential Data Set
- Specify the following parameters:
- Remote location
- Host code page
- Data set name
You can specify the data set characteristics in the next wizard
panel.
- Local file
- You can specify the parent folder in the next wizard panel.
- You can also select the following options:
- Add comment to generated program
- When the program is generated, comment templates are added.
- Open Snippets view when finished
- The Snippets view is a clipboard-like feature
that inserts chunks of text into source editors. You can use this
feature for chunks of code (for example, algorithms and data definitions)
that you commonly insert into any source file.
- Click Finish to create the program
or Next to continue to the next step.
- Perform one of the following actions:
- For a local file, select the parent folder in the Local
COBOL Program panel.
- For data set locations, select the data set characteristics
in the Data Set Allocation panel:
- Copy characteristics from an existing data set
- Select an existing connected data set.
- Specify characteristics by usage type
- You can set the following characteristics:
- Category
-
- Type
- ASM
- C/C++
- COBOL
- JCL
- PL/I
- REXX
- Specify characteristics
- Select this option to set advanced allocation characteristics.
- Click Finish to create the program
or Next to continue to the next step.
- If you specified a data set in step 5, specify
the characteristics for the new PDS or sequential file in the Data
Set Characteristics panel:
- Volume Serial
- Generic Unit
- Space Units
- Primary Quantity
- Secondary Quantity
- Directory Blocks
- Record Format
- Record Length
- Block Size
- Data Set Type
- Expiration Date
- Click System Managed Storage to
specify the following parameters:
- Data Class
- Storage Class
- Management Class
- Click Finish to create the program
or Next to continue to the next step.
- In the COBOL Program Features panel,
select the features to be used in the COBOL program.
Features
provide a way to initially generate COBOL programs that perform operations
similar to other programs. This initial generation is accomplished
by naming and using common sections of code that go in each division.
- To set the features, select one or more
of the following checkboxes:
Use BMS Maps
Invoke CICS commands
Use SQL statements
Handle SQL error return codes
- Click Finish to create the program,
or select features and click Next to continue
to the next step.
- Optional: In the COBOL Compiler Options panel,
override compiler options.
- Click Finish to create the program.