When the COBOL editor is used to create or edit a COBOL source file, the file format conforms to the rules specified under a reference format. The COBOL editor supports the following two reference formats:
Fixed format
Variable format
Free format
Specifying a reference format
To specify a reference format:
Select "Window" > "Preferences" from the menu bar. The "Preferences" dialog box appears.
Select "COBOL" > "Editor" in the left pane. The "Editor" page is displayed.
Click the "Reference Format" tab. The "Reference Format" page is displayed.
Select "Fixed format ", "Variable format" or "Free format" for the "Reference format".
"SRF and TAB compile option setting to be consistent with the applicable editor setting" checkbox
If it is checked, the value of SRF is consistent with "Reference Format" setting, and the value of TAB is consistent with "Tab width" setting. And if it is not checked, these changing settings do not occur.
COBOL editor operation for the fixed format
Columns 1 to 6 in the COBOL editor are used for line numbers, which are called sequence numbers.
"/", "D", "d", or "*" in the indicator area indicates that the line is a comment line.
"D" or "d" in the indicator area indicates that the subsequent text is debugging information. This option is valid for builds that are executed in debug mode.
Columns 8 to 11 are used as the A area, and columns 12 to 72 are used as the B area.
Column 73 and subsequent columns are used as the program identification area.
COBOL editor operation for the variable format
Columns 1 to 6 in the COBOL editor are used for line numbers, which are called sequence numbers.
Column 7 is used as the indicator column.
"/", "D", "d", or "*" in the indicator column indicates that the line is a comment line.
"D" or "d" in the indicator area indicates that the subsequent text is debugging information. This option is valid for builds that are executed in debug mode.
Columns 8 to 11 are used as the A area, and columns 12 to 251 are used as the B area.
The text in column 252 and subsequent columns is treated as a comment.
COBOL editor operation for the free format
You do not need to distinguish among the sequence number area, the indicator area, the A area, and the B area. You can start the source program at any positions in each line.
If a line contains "*>", the part from that point to the end of the line is treated as a comment.
Combining three COBOL characters ">>D" immediately followed by a single-byte space indicates a debugging indicator. A line with zero or one or more blanks before the debugging indicator is called "debugging line". The debugging line leaves debugging information in the source program.
The text in column 252 and subsequent columns is treated as a comment.
Note
A reference format can be changed. If changes have been made in a file but not yet saved, a message prompting the user to save the changes in the file is displayed before the reference format is changed.
To save the changes made in the file and then change the reference format, click the Yes button. To change the reference format without saving the changes, click the No button.