‎2011 Mar 08 6:24 PM
Hi,
I am running through a problem where I want to capture the user decision and according to that run the BDC.
Here's the explaination.
While running the bdc 1 pop up will come which will decide whether to proceed or not.
If your selects 'do not proceed' then need to run the flush part of the bdc else data saving part of the bdc.
So I want to capture the ucomm in the bdc and then proceed accoringly
Thanks for your help.
Anmol Bhat.
‎2011 Mar 09 6:16 PM
I believe I did something similar a few years back.
I had to create a partial BDC to get to the point of response from the popup.
Then I restarted the BDC & ran to completion based on input.
might sound goofy... but it worked.
can't remember how I got the response out.
might have been in an sy-field
‎2011 Mar 08 6:33 PM
*-------------------
*double post...
*-------------------Edited by: Sebastian Bustamante on Mar 8, 2011 7:33 PM
‎2011 Mar 08 6:33 PM
make a recording using transaction SHDB and see what happens....
regards, Sebastian
‎2011 Mar 08 6:36 PM
No dear it is not like that,
while running the bdc 1 popup screen will come, user can click cont or cancel if he click cancel i have to go back else save the data.
So i need how to capture user command within running bdc..
I think now it is more clear.
‎2011 Mar 08 6:47 PM
maybe debugging the popup and see the sy-ucomm?
theck this to debug a popup [http://wiki.sdn.sap.com/wiki/display/ABAP/ABAPTip-HowtoDebugPop-up+window]
‎2011 Mar 08 6:54 PM
I know the ucomm for both the buttons dear, the question is how to capture it..
Yes Keshav I also think this may be the solution, but any other possibility ?
Thanks ,
Anmol
‎2011 Mar 08 6:58 PM
Yes Keshav I also think this may be the solution, but any other possibility
Since the SHDB recording gives you the hardcoded User command values along with the screens which is predefined before program execution .... i dont find any other way.
‎2011 Mar 08 9:24 PM
‎2011 Mar 08 6:39 PM
Hi Anmol,
I am not sure of any other way .. One idea came to my mind. just after clicking the button check with implicit enhancements or badis where you can export the ok_code to memory and access it in your program and then toggle your screens.
‎2011 Mar 08 9:33 PM
>
> Hi Anmol,
>
> I am not sure of any other way .. One idea came to my mind. just after clicking the button check with implicit enhancements or badis where you can export the ok_code to memory and access it in your program and then toggle your screens.
Keshav, I am curious, even if we capture the UCOMM , how would the OP use it in his custom program? Wouldn't that be a whole new CALL transaction?
@anmol, I am curious as to why you want to provide this ability to users? If they are not sure of their path, they can always use the online transaction right? Granted, they have to manually key in the data.And what happens today, when they want to go back ?
‎2011 Mar 09 1:59 PM
Hi,
I was looking something like if the user hits opt1 it should do some data savind part of the bdc or if he hits opt2 then it should do the flush part of the bdc..
I think this is hardly possible... any suggesion on this......
Thanks,
Anmol.
‎2011 Mar 09 3:51 PM
Not really possible in my opinion, BDC implies that you have prepared a fixed and correct path through the screen sequence from beginning to end before starting the processing. Just like TV before it became interactive
Thomas
‎2011 Mar 09 6:16 PM
I believe I did something similar a few years back.
I had to create a partial BDC to get to the point of response from the popup.
Then I restarted the BDC & ran to completion based on input.
might sound goofy... but it worked.
can't remember how I got the response out.
might have been in an sy-field
‎2011 Mar 09 6:54 PM
Hi Doug,
Your ans souds good, it will be greate for me if you get some time to recollect that part.
Thanks a lot,
Anmol.
‎2011 Mar 09 8:04 PM
Well, you can prepare a partial transaction to run in mode "E" (maybe even "N", not sure), then it stops on the desired screen and the user can do the rest manually. But how to make it continue from there in background, even branching into a different screen flow based on user input? I'm very interested to learn this as well.
Thomas
‎2011 Mar 09 8:42 PM
@Thomas, my assumption is this BDC program is executed in the foreground? If it were to be executed in the background, would there be a user response to popup?
‎2011 Mar 09 10:14 PM
Sorry, I meant "dark" processing, as in a call transaction with mode "N" or "E".
Thoma