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 not goving back!!!!

Former Member
0 Likes
611

hi Exprets!!

i am working on the screen programing and i have screen 9001 and in that i have set of fields to be inputed. i have used chain--endchain in PAI for those fields. but problem is when i process the report the screen i designed is not going back until i fill all the details of the input fields. how to avoid this.its getting struck at that screen.

plz reply me..

mahesh

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
587

Hi,

Try this piece of code.

MODULE exit_command INPUT.

 IF g_ok_code = 'BACK' OR
    g_ok_code = 'RW' OR
    g_ok_code = 'EXIT'.
  
IF sy-dynnr = 9000.
      LEAVE PROGRAM.
    ELSE .
      LEAVE TO SCREEN 0.
    ENDIF.
ENDIF.

ENDMODULE.

Hope this will solve ur problem.

plz reward if useful.

thanks,

dhanashri.

5 REPLIES 5
Read only

Former Member
0 Likes
587

Hi , You need to code to which screen u need to go when back or exit is pressed in PAI. in the Module User_command. Else it will keep calling the same screen again and again.

Murali.

Read only

0 Likes
587

hi

i have coded that in PAI.

but still its getting struck

Read only

Former Member
0 Likes
588

Hi,

Try this piece of code.

MODULE exit_command INPUT.

 IF g_ok_code = 'BACK' OR
    g_ok_code = 'RW' OR
    g_ok_code = 'EXIT'.
  
IF sy-dynnr = 9000.
      LEAVE PROGRAM.
    ELSE .
      LEAVE TO SCREEN 0.
    ENDIF.
ENDIF.

ENDMODULE.

Hope this will solve ur problem.

plz reward if useful.

thanks,

dhanashri.

Read only

Former Member
0 Likes
587

hi......

In

MODULE screen_9001 AT EXIT-COMMAND.

you can write loic for back,cancel and exit.

when you use E-type of functions the validations are not checked and it will come out of the screen.

in the above module you can write set creen 0.

leave screen.

or directly write leave program.

Read only

Former Member
0 Likes
587

thanks all