Structure files and the record layouts within them cannot be created or viewed in
Data File Editor. You must create the structure file and record layouts using the Classic Data File Tools product; after which, you can apply
the resulting
.str file to your data files in
Data File Editor.
-
From a Visual COBOL or Enterprise Developer command prompt, type
mfdatatools, then press
Enter.
-
On the
File menu, click
New, then select
Record Layout and click
OK.
The
Select a file to construct the layouts from dialog box appears.
-
Navigate to and select the debug information file (.idy file) from a program that uses the data file for which you are creating this structure file, then select
Open.
A Layout window appears, showing the Data Division of the COBOL program.
-
Create a default layout (optional):
-
From the left-hand pane, right-click the top-level data item on which to base your layout, then select
New Layout.
The
New Record Layout Wizard dialog box appears.
-
Select
Default Layout, then click
Next.
-
Click
Finish.
The default layout is displayed in the right-hand pane.
-
Create a conditional layout (optional):
-
From the left-hand pane, right-click the top-level data item on which to base your layout, then select
New Layout.
The
New Record Layout Wizard dialog box appears.
-
Select
Conditional Layout, then click
Next.
-
Click
Finish.
The conditional layout is displayed in the right-hand pane.
-
Expand the layout to locate a field on which to base a condition, then double-click it.
The
Field Properties dialog box appears.
-
Click
and select an operator from the Condition list, then add the appropriate value(s) to the right.
-
Click
OK.
-
Repeat the last three steps if you need to add more conditions. (All conditions must be met for the layout to be used.)
-
On the
File menu, click
Save.
The
Save As dialog box appears.
-
In the
File name field, type a name for the structure file, then click
Save.
The structure file is saved. To use it, you must specify its path and filename when creating or opening a data file.