The Design view of a Program

This view displays, in a read-only mode, the design of the generated instance whose code is currently displayed in the PDP COBOL editor and selected.

To see the content of this view, you must have generated a Program, Screen, or Server. Then, from the Design Explorer view or the result view of a local or server instance or reference search, open the generated file by right-clicking it and selecting the PDP COBOL editor. For example, for a Program generated file, select Open with > PDP COBOL editor in the contextual menu of the generated Program. The editor must remain opened and currently selected.

The design elements are constituted of the attributes and resources of the instance. You do not modify them directly in the Design view but in the design editors. You can right-click an attribute or a resource in the Design view and select Open editor in the contextual menu to open the appropriate design editor.

As soon as you modify the design in the design editor of the instance itself or of one of its called instances, the modifications are visible in the Design view. If you close the design editor without saving and if the instance is not opened in another editor, the modifications are discarded in the Design view.

Description of the view

This view shows a hierarchical view of the design elements.

The Attributes category contains the same information as the Definition tab of the instance.

The other tree categories represent the Program resources:
  • Input files, Output files, Input/Output files, and Reports represent the external resources of the Program. These categories contain the same information as the -CD Lines tab.
  • Working files and Working data represent the internal resources that are called in the WORKING-STORAGE SECTION.
  • Macros displays the same information as the -CP Lines tab.
This view contains a toolbar from which you can Generate the code (Generate the code). If you have updated the design of a Program, Screen, or Server, the newly generated code will integrate the changes in the design, while keeping any specific changes in the code. The design must be consistent. When the design of the instance is modified, the generated COBOL can no longer be synchronized. In this case, the color of the toolbar button that is used to generate changes (Generate is recommended due to modifications in the design) to indicate that Generate is recommended due to modifications in the design. Once the generation is complete, the synchronization is restored and the toolbar button returns to its initial appearance.
Note:

The preference Structure checking before generation management, which is available from Window > Preferences > Pattern Driven Programming > Pacbase Patterns, checks that the nesting of subfunctions in the COBOL code is correct before the generation. By default, it blocks the generation if structure errors are detected.

Limit: The Undo and Redo functions of the editor are no longer available after a generation. The pile of changes to undo and redo is emptied after each generation. The changes that are made before a generation cannot be undone with the Undo function. To delete changes (including the generation) made before the generation, you can exit the editor without saving or use the Revert File function.

Feedback