When a Program, Screen, or Server is duplicated, all the associated generated files (metadata file, COBOL file, and Screen map file) are also duplicated. To open the duplicating wizard, select a Program, Screen, or Server in the Design Explorer view and select Duplicate in the contextual menu.
When you open the duplicating wizard, various fields display the values of the initial instance. You must modify some values, which must be unique.
The initial project is selected by default but you can select another project in the drop-down list. This list displays the target projects whose required projects are the same as those of the initial project. Then, all the references will be resolved in the new project.
The project that is displayed when the wizard opens is the project from which you started the duplication. You can select another project in the drop-down list. This list displays all the projects of the local workspace.
In this case, this field displays, by default, the folder that is indicated in the initial project. You can enter another folder as a name or a file path. If the new folder does not exist, it is automatically created.
However, it is advised to keep the default folder to group all the generated files in the same folder.
This name must be different from the COBOL name of the initial instance, whose unicity is based on the concatenation of the project, the folder, and the PROGRAM-ID. It must not already be used in the project.
This project is the target project for the duplication of the map file.
The project that is displayed when the wizard opens is the project from which you started the duplication. You can select another project in the drop-down list. This list displays all the projects of the local workspace.
Moreover, it is available only if a map folder is indicated in the properties of the initial project to replace the default rpp value.
In this case, this field displays, by default, the folder that is indicated in the initial project. You can enter another folder as a name or a file path. If the new folder does not exist, it is automatically created.
However, it is advised to keep the default folder to group all the generated files in the same folder.
This name must be different from the map name of the initial instance. It must not already be used in the project.
Indicate the required values and click Finish.
For Programs and Servers, the duplicated design and COBOL code have the same subreferences as the initial design and COBOL code. The duplication modifies all the appropriate fields in the target COBOL code. Then, you can use the target COBOL file as is.
For Screens, the duplication does not modify the Screen name in the parameters of the Macros that are called in the Screen. So, you must open the - CP Lines tab of the Screen and enter the new name in the appropriate parameters of the Macro. You must then generate the Screen again.