Application Development 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: 

leave to selection screen

Former Member
0 Kudos

Hi all,

I am doing an ALV with oops. I am in screen 0001 now. If I select BACK fcode , it should go to previous screen (in this case selection screen 1000).How can I do this? I have tried with

leave to screen 0.

call screen 0.

But it's not working. It's coming out of that selection screen also.

And I have tried with

call selection-screen 1000.

It's working but, when I select BACK from here, it's going to the ALV screen 0001 again.

Please help.

1 ACCEPTED SOLUTION

Former Member

Hi,

Use

LEAVE TO SCREEN 0

Regards

Nandha

11 REPLIES 11

Former Member
0 Kudos

Hi,

Try using SET SCREEN 1000.

0 Kudos

Hi,

it's not working,throwing error like screen 1000 is not called using CALL SELECTION-SCREEN statement.

0 Kudos

I ususally Code using the LEAVE TO SCREEN 0, which is working for me..,

CASE OK_CODE.

when 'BACK'.
leave to screen 0.

ENDCASE.

where you are calling the screen 0001 , i.e which event you are calling. Calling it under end-of-selection event.

0 Kudos

Yes, I am calling it after event END-OF-SELECTION.

I have called the screen like SET SCREEN 0001.

I have tried with LEAVE TO SCREEN 0. But it's not moving back to selection screen , it's moving totally out of the report.

0 Kudos

it all depends on how you are calling screen and navigating. I never faced any problems with the screen navigation. I am sure you are doing some mistake., just try with small code and see how it works, if its not working then post that code here...

0 Kudos

Hi Vijay,

earlier I have used SET SCREEN 001. Then LEAVE TO SCREEN 0 didn't work.Now I have used CALL SCREEN 001. Then LEAVE TO SCREEN 0 is working. What is the exact difference bet. SET SCREEN and CALL SCREEN?

0 Kudos

Just Read the F1 help of those, it is explained clearly.

when you use SET SCREEN , you have to use LEAVE SCREEN.

not the LEAVE TO SCREEN 0. "Wrong This is the mistake you are doing.

SET SCREEN + LEAVE SCREEN = LEAVE TO SCREEN <scrno>

Differences Discussed many times in the General forum, Just give a small search.

0 Kudos

Hi,

SET SCREEN 1000 is used to define the next screen as 1000.

But call screen is used to call any screen from the current screen.

0 Kudos

Thank u all.

Former Member
0 Kudos

Hi,

For the screen BACK Button use function code 'BACK'.

Case sy-ucomm.

when 'BACK'.

leave program.

endcase.

this is call selection screen.

Regards,

Madhavi

Former Member

Hi,

Use

LEAVE TO SCREEN 0

Regards

Nandha