‎2009 Jun 23 9:39 AM
Hi All,
Is there any statement or function module where in i can check what all variables are used within a ABAP program.
Ex: For the below code:
DATA : lv_name(30) TYPE c,
CONSTANTS: lc_name(30) TYPE c VALUE 'NAME'.
I need info like: lv_name, DATA, c
lc_name, Constant, c.
Thanks in advance.
‎2009 Jun 23 9:45 AM
Hi,
You can use SCAN ABAP-SOURCE statement .
In this you will get the whole abap code of a report into tables as tokens, statements
you have many more additions available with this statement.
check this link for more information about [SCAN ABAPSOURCE|http://help.sap.com/abapdocu/en/ABAPSCAN.htm]
Thanks&Regards
Sarves
‎2009 Jun 23 9:47 AM
I have tried using SCAN ABAP-SOURCE but the tokens are not useful as i need to know the type each token is. Like if it is a constant i have to get an output stating its a constant.
Thanks for the quick response.
‎2009 Jun 23 10:02 AM
‎2009 Jun 23 9:46 AM
Hi,
You can check that by using FIND icon on the standard tool bar.
Otherwise you can use the below reports.
RPR_ABAP_SOURCE_SCAN
RS_ABAP_SOURCE_SCAN
Regards,
Kumar Bandanadham
‎2009 Jun 23 9:47 AM
Hope this Report gives some hint.
RPR_ABAP_SOURCE_SCAN
In the Find String, give 'DATA' and execute.