Alleged most ABAP Developers have encountered the fact that even commented code can work for forward navigation.
The following snippets should work to comprehend via double click in your ABAP Editor.
The ABAP Editor finds the navigation target in commented code.
The crux seems to be that it makes a differences if you comment with * or ":
" call function 'POPUP_TO_SELECT_MONTH'. Doesnt´t find a navigation target
* call function 'POPUP_TO_SELECT_MONTH'. Jumps in the FM
It seems as if the Editor handles the code artefact like if you would double click on not commented code.
Thus, you get the where-used-list with the following comment:
* function 'POPUP_TO_SELECT_MONTH'.
Armed with this knowledge, we can help the reader of our code with "functional comments", as:
* refer to CL_GUI_CFW=>DISPATCH( ).
or
* also look at fields: mara-matnr, mara-blatt
One more thing to mention is that it can help to make clear where the command starts, respectively where the last command ends. See this:
* we could raise exception type cx_some_error. does not work
* we could. raise exception type cx_some_error. works
One last example:
* check usages of program ZWOL_COMMENT_NAVIGATION. does not work
* check usages of. program ZWOL_COMMENT_NAVIGATION. works
What a bummer that double click does not resolve macros. Imagine what would have been possible with macros...
What I didn´t figure out is why this works even without the . after can:
* you can include mara in your thougts.
All examples did work as described in my SAPGUI. No guarantee that this works on every GUI and in all (future) versions.
Apart from that, it is better to write code which doesn´t need additional explanations by any comments...
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
25 | |
5 | |
4 | |
2 | |
2 | |
2 | |
2 | |
2 | |
2 | |
1 |