Rational Programming Patterns

Macro COBOL editor

This editor is used to modify the source code of Macros that are retrieved from different models (batch or client for example). It consists of a source code textual editor, in which you enter the code, and of a Macro code structure view, which displays the nodes hierarchy of the Macro.

You access the Macro COBOL editor from the COBOL Source tab of the Macro design editor. To open it, double-click a Macro instance in the Design Explorer view: the editor opens on the COBOL Source tab by default. You can also right-click and select Open with > COBOL and model Macro editor.
The Macro COBOL editor offers the standard features and characteristics of the COBOL editor.

You can identify the Macro lines with their colors. These colors can be modified in the preferences of the COBOL editor. To open the preferences wizard, select Window > Preferences > COBOL > Editor > Syntax coloring in the menu bar. You can also right-click in the Macro COBOL editor and select Preferences.

The Copy and Paste choices are available if you right-click in the editor

Code can be inserted easily with micropatterns and snippets. The snippets that are specific to Macros are available from the RPP Macro snippets in the Snippets view. When the instance that calls the Macro is generated, the micropatterns are recognized and the corresponding code lines are automatically generated.
Note: You might see a DOT annotation in the column 73 of the COBOL code. This annotation replaces the 99BL notion. You must not delete it because, after the generation, it is replaced by a dot at the end of the previous significant line.
A creation wizard for functions and subfunctions is available if you right-click in the Macro COBOL editor. Functions and subfunctions are inserted in the COBOL code according to their code. You can create them in any order: you can create a function 14 before a function 02 for example. The cursor position is irrelevant. With the wizard, you can insert functions and subfunctions in different ways:
  • Insertion in an absolute mode, with no positioning relative to automatic functions or subfunctions.
  • Insertion relative to the automatic functions or subfunctions of the Standard or client Dialog model
  • Insertion relative to the automatic functions or subfunctions of the Business Component model. The following insertions are possible:
    • Insertion relative to a 05 hierarchical level
    • Insertion relative to the SQL processing
    • Insertion relative to the Logical View processing
    • Insertion relative to the logical access level
    • Insertion relative to the physical access level

Terms of use | Feedback

This information center is powered by Eclipse technology. (http://www.eclipse.org)