Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Finding for includes in customized programs

Former Member
0 Likes
563

Hi,

My requirement is to get all include objects in several customized programs. I am making use of the functionality in std program RPR_ABAP_SOURCE_SCAN.

With the result from above, I get the listing of includes. My program needs to clean the output list to <u>only</u> derive at the include's object name. Please refer to examples below to see how include statement being programmed in several ways.

How would you best recommend that i split/search to only get the object names, or is there a tool in SAP that could help?

Examples:

<b>a. INCLUDE ZMKTEST_INCLUDE1            .
b. INCLUDE ZMKTEST_INCLUDE1
       .
c. INCLUDE:ZMKTEST_INCLUDE1,         
           ZMKTEST_PERFORM.  "INCLUDE ZMKTEST.
d. INCLUDE  :  ZMKTEST_INCLUDE1.   "   , ZMKTEST_PERFORM.
e. INCLUDE:ZMKTEST_INCLUDE1      "INCLUDE ZMKTEST
           ,ZMKTEST_PERFORM.</b>

PS: There is no meaning for the red colour above, I'm using "code" formating for the above to distinguish my explanations and the examples, but somehow it returns some words in red colour.

1 ACCEPTED SOLUTION
Read only

uwe_schieferstein
Active Contributor
0 Likes
514

Hello

You can use function module <b>RS_GET_ALL_INCLUDES</b> to determine all includes in a program.

Regards

Uwe

3 REPLIES 3
Read only

venkata_ramisetti
Active Contributor
0 Likes
514

Hi,

YOu can just use table WBCROSSI to find all includes for a main program.

For example I created a program as follows.

REPORT ZPROG2 .

start-of-selection.

include zinclu1.

include zinclu2.

After that I go to SE16 and gave table nale WBCROSSI and specified ABAP/4 main program field (MASTER) as ZPROG2.

It returned with two entries.

zinclu1

zinclu2

Thanks

Ramakrishna

Read only

0 Likes
514

Hi Ramakrishna,

Thanks for your reply.

But I am in version 4.6C, and the table is not available in my system. Please help.

Read only

uwe_schieferstein
Active Contributor
0 Likes
515

Hello

You can use function module <b>RS_GET_ALL_INCLUDES</b> to determine all includes in a program.

Regards

Uwe