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

screen in user exit

Former Member
0 Likes
1,778

helo

ive added code in user exit for tcode va01, in the code ive added a pop up window

after the popup window,we shd return to the current screen, i used the command LEAVE TO SCREEn, and at the end of the user exit, i used the command LEAVE SCREEN.

But then the data is not saved, if i dnt use the LEAVE SCREEN, we cant exit from the current screen and if i use the LEAVE SCREEN, the data is not saved

does anybody know how to handle this??

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,401

Hi Anjali,

As u said the pop screen is only used to display information to user before saving...I think in this case you can make use of USEREXIT_SAVE_DOCUMENT in the include program MV45AFZZ. This is a user exit provided by SAP which will be called before the document is saved...

Here we can make use of the Function Module to POPUP_TO_CONFIRM to display the message to user and can proceed if user confirms...

Please let me know if my understanding is wrong.

Regards,

Swaroop

helo

ive added code in user exit for tcode va01, in the code ive added a pop up window

after the popup window,we shd return to the current screen, i used the command LEAVE TO SCREEn, and at the end of the user exit, i used the command LEAVE SCREEN.

But then the data is not saved, if i dnt use the LEAVE SCREEN, we cant exit from the current screen and if i use the LEAVE SCREEN, the data is not saved

does anybody know how to handle this??

7 REPLIES 7
Read only

Former Member
0 Likes
1,401

Hi Anjali ,

u cannt call like this in SD user exits , tell me what problem u are facing , i will try to give Diff Solution.

Regards

Prabhu

Read only

0 Likes
1,401

ok,

i have to display a popup window after making some checks on the screen before saving the order on VA01, then come back to the screen and save the order

the problem is after dispalying the popup, the order is saved and the screen is exited

i want to be on the current screen after the popup, save the oder and go out of the screen

Read only

Former Member
0 Likes
1,401

Sia,

Try to use

<b> leave to screen 0.</b>

can you give some more details...

what exactly the popup shows and what you are doing there...

Regards

Vijay

Read only

0 Likes
1,401

the popup just informs the user about the changes he made, thats all!

Read only

Former Member
0 Likes
1,402

Hi Anjali,

As u said the pop screen is only used to display information to user before saving...I think in this case you can make use of USEREXIT_SAVE_DOCUMENT in the include program MV45AFZZ. This is a user exit provided by SAP which will be called before the document is saved...

Here we can make use of the Function Module to POPUP_TO_CONFIRM to display the message to user and can proceed if user confirms...

Please let me know if my understanding is wrong.

Regards,

Swaroop

Read only

0 Likes
1,401

no, thats wat ive done

ive used the fm POPUP_TO_DISPLAY_TEXT

my problem is after the popup, the screen is exited and i want to stay on the screen after the popup

i used the command leave to screen 4001

but then wen the order is saved, we cant go out of the screen

to go out of the screen, i wrote LEAVE TRANSACTION but then the order is not saved

Read only

0 Likes
1,401

Oh ok...I am not very sure just try with POPUP_TO_CONFIRM FM as this is a Modal Dialogbox which waits for a User Input..let me know if this works...