Application Development 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: 

How can you determine the calling program?

Former Member
0 Kudos

I know if you want to determine the calling tcode you do sy-tcode but how can I determine what the calling program was?

I have an output requirement and, right now, there is an if statement like the following:

if sy-tcode = 'vf01' or sy-tcode = 'vf02'
perform vf02_routine.
else.
perform va02_routine
endif.

I want to add a check to see if the calling program was SAPMV60S, is there a way to do that?

Regards,

Davis

1 ACCEPTED SOLUTION

RichHeilman
Developer Advocate
Developer Advocate
0 Kudos

check SY-CPROG

Regards,

RIch Heilman

4 REPLIES 4

RichHeilman
Developer Advocate
Developer Advocate
0 Kudos

check SY-CPROG

Regards,

RIch Heilman

0 Kudos

Ah, thanks. I was trying sy-program. Is there a listing of all sy-#### calls?

Davis

0 Kudos

open structure SYST in se11, you will get all SY variables