2006 Dec 14 7:53 PM
I am trying to start multiple foreground sessions from a 'driver' module asynchronously.
I have tried various forms of the call transaction, submit report and wrapping the code in a function module that I have called asynchronously. The function module will start an independent session, but as a background task instead of foreground one.
Anyone have any ideas or tried this before?
Thanks.
2006 Dec 14 8:40 PM
Yes, you can do it like this.
report zrich_0001.
data: session_name type string.
do 3 times.
session_name = sy-index.
call function 'ABAP4_CALL_TRANSACTION'
starting new task session_name
destination 'NONE'
exporting
tcode = 'SM50'
exceptions
call_transaction_denied = 1
tcode_invalid = 2
others = 3.
enddo.
Regards,
Rich Heilman
2007 Jan 10 6:40 PM
Hi Rich,
Sorry about the lag in my response. The place I work shuts down over XMAS and I took some extra vacation.
I tried the function module you suggested. It works with the Dialog transactions I tried it with. I had tried doing something similar with a function module I wrote, ie using a call transaction in the function module, as well as using a submit report and recording the execution of the report in a BDC and wrapping it a function module and calling it asynchronously. None of them work, although the asynchronous call opens a new session. All I can figure is reports, ABAP or Painter, work different than the Dialog?
Any other ideas.
Thanks, Russ.