Renaming an instance

You can rename a selected instance while seeing the impact of its renaming. The new name is automatically propagated to all the design files where the instance is used. For Data Elements, the new name is also propagated to all its usages in the Macro code or the specific code of Programs, Screens, and Servers.

Procedure

  1. Right-click an instance in the Design Explorer view and select Refactor > Rename.
  2. Enter the new name in the wizard that opens.
  3. You can start the renaming directly or you can choose to see its impacts first.
    • Click Finish to start the renaming without seeing its impacts.
    • Click Next to see the impact of the renaming. The following two tabs are then displayed:
      • The Renames tab lists all the design files that will be renamed. For example, in the Pacbase facet, it lists all the Segments that will be renamed after the renaming of a Data Structure.
      • The Changes tab lists all the files that will be impacted by the renaming. It lists all the design files where the instance is called.

        For Data Elements, it also lists the Macros that call the Data Element in their code, and the Programs, Screens, and Servers that calls the Data Element in their specific code.

      Click Finish to start the renaming.

Results

To ensure the consistency, the instance is renamed in all the design files impacted. These files are the instances whose names are based on this instance name (Segments of a renamed Data Structure for example) or the instances that call the renamed instance in their design.

Moreover, if the renamed instance is a Data Element that is called in the code of a Macro or in the specific code of a Program, Screen, or Server, it is also renamed in these usages. The impacted Programs, Screens, and Servers are automatically generated again to avoid any desynchronization.


Feedback