Context
You can change all occurrences of an element (except ABAP keywords) in an ABAP
program at the same time.
Procedure
- In the source code editor, position the cursor on the element to be renamed.
- Start the
Rename function function using the context menu and
then Rename x in source unit (Ctrl 2, R)).
A frame appears around each occurrence of the element.
Figure 1:
Highlighted position of the element that is edited and all further
occurrences of the element
- Type in your change. The ADT makes the change simultaneously in all occurrences of the
element in the source code unit you are currently working in. This technique is
only allowed for named elements that occur only in your current source code
unit. For example, you cannot use this technique to rename elements in a method
implementation if the named element is also used in your ABAP Unit tests.
Results
You have renamed an element in your source code throughout the source code unit you
are currently working in.