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

Modal Window from Subscreen

Former Member
0 Likes
1,461

Hi,

I'm developing a Badi for the EWM Packing dialog and facing the following problem: Within in my Badi-Tab which is a subscreen i have to call a modal window to get some values from the user!  Is it possible to go back to the calling subscreen?

I tried the following code lines in my at-exit module:

LEAVO TO SCREEN 0                => The program is closing

LEAVE TO SCREEN                    => DUMP DYNP_WRONG_SCREEN_TYPE

LEAVE SCREEN                          => DUMP DYNP_WRONG_SCREEN_TYPE

EXIT                                                => DYNP_WRONG_SCREEN_TYPE

CALL TRANSACTION                 => DYNP_WRONG_SCREEN_TYPE

Any ideas or workarounds for that?

Thanks in Advance

Tobias

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,040

set screen 0. LEAVE SCREEN. -> this works the same as leave to screen 0.

You need to call it as a popup - there should be no problem with popup calls in the subscreen. Why dont you just use

CALL SCREEN XYX STARTING AT a b. -> this will call the modal popup. Now the program process flow goes to the subscreen. Once you use LEAVE TO SCREEN 0 in the popup, you are going back to the place, where the popup was called. Just place a breakpoint there and you will see.

4 REPLIES 4
Read only

Former Member
0 Likes
1,040

SET SCREEN 0.

LEAVE SCREEN.

Read only

0 Likes
1,040

DEBOPRIYO MALLICK wrote:

SET SCREEN 0.

LEAVE SCREEN.

Nope, the program is closing and the selection screen appears

Read only

Former Member
0 Likes
1,041

set screen 0. LEAVE SCREEN. -> this works the same as leave to screen 0.

You need to call it as a popup - there should be no problem with popup calls in the subscreen. Why dont you just use

CALL SCREEN XYX STARTING AT a b. -> this will call the modal popup. Now the program process flow goes to the subscreen. Once you use LEAVE TO SCREEN 0 in the popup, you are going back to the place, where the popup was called. Just place a breakpoint there and you will see.

Read only

0 Likes
1,040

Oh thanks jozef, the sy-ucomm for the X in the modal is CANCEL with this CANCEL i come back to calling pai which i have a leave screen 0.

Thank for the push