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

BACK function key

KumarVishal
Participant
0 Likes
1,443

Hi Expert,

On a ALV grid display ..using button I am moving to another screen 200...then again click on button moving to screen 300 which

displays a ALV List.

But a 'BACK' Function Key is there in screen 300. BUT this is not working.ON clicking this back button its going to a hibernate kind

of state.Actually screen 300 PAI is not getting executed on clicking back button

WHY?

PLZ give a solun.

6 REPLIES 6
Read only

Former Member
0 Likes
983

Hi Vishal,

Can you give the code extracts for each screen's PAI events ? What are the Fcodes u r using for BACK button on each screen ? Give different names to OK_CODES in each screen under elements tab.

code extracts of USER_COMMAND for each screen will be of help to find out the cause.

Regards,

Vishram

Read only

0 Likes
983

I am using BACK as function key ...so FCODE is "BACK"....and tried giving different ok_codes to all screen.

What not solved...

Actually I am moving from screen 200 to 300 ..but when i am leaving back to screen 100 ...the screen 200 pop-up remains.

Read only

Former Member
0 Likes
983

please check that in gui status of screen 300 you have defined BACK button or not and if defined please check the attributes.

Read only

Former Member
0 Likes
983

1. CHeck your PF STATUS. IF BACK BUTTON IS ACTIVE THERE.

ALL YOU HAVE TO DO IS to write acode.

CASE SY_UCOMM.

when 'BACK'.

Leave to screen -<YOUR PREVIOUS SCREEN NAME>.

Reward if find it useful

Read only

KumarVishal
Participant
0 Likes
983

Actually in screen 300 I am displaying a alv using "REUSE_ALV_LIST_DISPLAY"... this is in PBO of screen..

ON click back function key it is never going to the PAI of the screen..

SO do I need to pass some ...user action or command alos to REUSE_ALV_LIST_DISPLAY function module..

there is a field for that???

Read only

0 Likes
983

Hi Vishal,

If I understood your problem correctly , then i guess you need to write below code:

My Understanding of your issue : screen 100 -> pop up screen 200 ->screen 300 and when you click "BACK" Button from screen 300, you want to go back to screen 100 instead of screen 200's pop up.

Solution : Please write below code before calling SCREEN 300.

IN PAI OF screen 200. 
                IF Ok_code_200 EQ 'OK'
                   SET SCREEN 0.
                   CALL SCREEN 300.
                     " write your logic....
               ENDIF.

In  PAI of 300, write below code.
	PROCESS AFTER INPUT.
	MODULE exit_command_305 AT EXIT-COMMAND.
      (IN PF-STATUS of screen 300 - while maintaining Function Code, Write Function type as 'E' for "Back" button )
	MODULE exit_command_305 INPUT.
	  IF ok_code_305 EQ 'CANCEL'.
	    LEAVE TO SCREEN 0.
	  ENDIF.
	ENDMODULE.

I hope this will help you.

Regards,

Rahul Mahajan