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 flow issue

VenuAnumayam
Participant
0 Likes
843

Hello Experts,

I have designed my first module pool programming application. On the first screen (Screen# 9000) when the users click on a button, it will show a pop-up(Screen# 0100). When the users click on "Cancel" button on the pop-up, it should go back to the first screen (Screen#9000) - which is working fine. However, when the users click on the "Green Arrow/F3/BACK" button, it is showing the pop-up screen again instead of getting out of the screen.

Can you please let me know what went wrong.

Thanks.

Here's the flow-logic for screens:

Screen#9000

Moderator message - Please respect the 2,500 character maximum when posting. Post only the relevant portions of code

Edited by: Rob Burbank on Nov 16, 2009 4:23 PM

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
811

you might not clearing Okcode. try to debug.

6 REPLIES 6
Read only

faisalatsap
Active Contributor
0 Likes
811

Hi, Ravi

Check this one ==>

Your Post's Characters are almost 2554 so it is not in proper format and hard to understand for every one..

Please check this and always do search before posting, i think you can solve out your problem after little Search..

You are Member Since 2006 you must know about the Forum Rules, Your Subject Line is also not proper one, Please use Meaningful Subject Line for your next time posting.

Best Regards,

Faisal

Read only

Former Member
0 Likes
812

you might not clearing Okcode. try to debug.

Read only

0 Likes
811

Sorry. I have modified the Subject now and reformatted the content of the post.

I have also debugged the code and found that the program processes the flow logic of 0100 again when it should come out.

Thanks.

The code for screen# 9000.

PROCESS BEFORE OUTPUT. 
MODULE STATUS_9000. 

PROCESS AFTER INPUT. 
MODULE USER_COMMAND_9000. 

*&---------------------------------* 
*& Module STATUS_9000 OUTPUT 
*&---------------------------------* 
MODULE STATUS_9000 OUTPUT. 
SET PF-STATUS 'STANDARD'. 
SET TITLEBAR 'STANDARD'. 
clear: ok_code. ENDMODULE. 

*&--------------------------------* 
*& Module USER_COMMAND_9000 INPUT 
*&--------------------------------* 
module user_command_9000 input. 

data: lt_rows type lvc_t_row. 

check not ok_code is initial. 

 case ok_code. 
  when 'FRZ_VERS'. 

*-- Call Pop-up screen to select version. 
   call screen '100' starting at 10 20 ending at 40 30. 

*-- When the user clicks on 'BACK' button. 
  when 'BACK'. 
   set screen 0. leave to screen 0. 

  when others. 
   set screen 0. 
   leave to screen 0. 
 endcase.

Screen# 0100.

PROCESS BEFORE OUTPUT. 
MODULE STATUS_0100. 

PROCESS AFTER INPUT. 
MODULE USER_COMMAND_0100. 

*&---------------------------* 
*& Module STATUS_0100 OUTPUT 
*&---------------------------* 
MODULE STATUS_0100 OUTPUT. 
  SET PF-STATUS 'FREEZE'. 
  SET TITLEBAR 'FRZ'. 

ENDMODULE.  
*&--------------------------------* 
*& Module USER_COMMAND_0100 INPUT 
*&--------------------------------*
MODULE USER_COMMAND_0100 INPUT. 
 case ok_code. 
  when 'CANC'. 
   if sy-dynnr = '0100'. 
    call screen 9000. 
   endif. 
  when 'BACK'. 
   set screen 0. 
   leave to screen 0. 
  when 'OTHERS'. 
   set screen 0. 
   leave to screen 0. 
 endcase. ENDMODULE.

Read only

0 Likes
811

case ok_code.

when 'FRZ_VERS'.

clear: ok_code -


> Add this here

*-- Call Pop-up screen to select version.

call screen '100' starting at 10 20 ending at 40 30.

*-- When the user clicks on 'BACK' button.

when 'BACK'.

set screen 0. leave to screen 0.

Read only

0 Likes
811

I have modified the PAI of 0100 screen, it worked.

Thanks for the help.

Read only

former_member191735
Active Contributor
0 Likes
811

Clear ok code if there is any or clear Sy-ucomm if you are using sy-ucomm in PAI user_command module