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

Program call via SUBMIT

mabue
Discoverer
2,400

Is it possible to determine in a program whether this program was called from another program via SUBMIT?

The function module "SYSTEM_CALLSTACK" or the class "CL_ABAP_GET_CALL_STACK" are unfortunately not usable for this.

I am grateful for any hint.

Best wishes

Marco

Sandra, that's a good idea with EXPORT-IMPORT. Why didn't I think of that? 😉

Frederic, if I'm honest, I don't understand how you mean that with the singleton class.

7 REPLIES 7
Read only

FredericGirod
Active Contributor
2,297

you could create a SingleTon class in the calling program. But this will not work if you are searching for solution without update calling programs

Read only

abo
Active Contributor
2,297

where the SingleTon class is the heavier version of the singleton? 😉

(ok, it's friday...)

Read only

FredericGirod
Active Contributor
2,297

I could do a DP_Single_Ton but matthew.billingham certainly lurk somewhere against Hungarian notation ...

Read only

Sandra_Rossi
Active Contributor
0 Likes
2,297

No (as far as I know).

You need to change the calling program to pass the information (either via EXPORT ... TO MEMORY ID ... or via new parameter).

Read only

0 Likes
2,297

Sandra ? you prefer the EXPORT ... IMPORT instead of the SinGlEtOn design pattern ??

Read only

0 Likes
2,297

frdric.girod I don't see how singleton pattern can overcome the Internal Session barrier. The singleton will exist only in Internal Session "1", it won't exist in Internal Session "2".

Read only

mabue
Discoverer
0 Likes
2,297

Sandra, that's a good idea with EXPORT-IMPORT. Why didn't I think of that? 😉

Frederic, if I'm honest, I don't understand how you mean that with the singleton class.