You will learn
- How to make your program more readable by learning how to maintain
ABAPDoc
comments. - How to synchronize the documentation and to display it, both in the ABAP Development Tools (ADT) and in SAP GUI.
Step 1: Open your ABAP class
First, open your ABAP class.
Step 2: Add an ABAPDoc comment
To improve readability, add an ABAPDoc comment to the class immediately before the method definition, for example:"! Method reads invoice items from database
.
NOTE: You must insert the ABAPDoc comment immediately before the declaration; otherwise you will get a warning from ADT.
ABAPDoc comments can be used to document APIs and are displayed in the Element Info. All ABAPDoc comments begin with "!
.
Step 3: Add parameters to ABAPDoc
You can also use ABAPDoc to document method parameters with a Quick Assist. Place the cursor inside of the ABAPDoc comment. Then choose **Ctrl+1**