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.
Showing results for 
Search instead for 
Did you mean: 

cl_gui_container=>screen0 and SELECTION-SCREEN: FUNCTION KEY 1

0 Kudos


I have a report where I have a normal selection-screen plus a SELECTION-SCREEN: FUNCTION KEY 1 to display another button.

If user uses this extra button a screen 100 it's called where I have an ALV.
This ALV is using CL_GUI_CONTAINER=>SCREEN0 as parent to display it in fullscreen.

Well, if I hit BACK in this screen 100 I put a LEAVE TO SCREEN 0 but its not returning to the selection screen, instead its returning to the same screen 100 but with the status of the selection-screen, and if I use BACK again then is leaving the program.

I've tried changing the "Next Screen" to blank or 1000 but is not working.

If I change the CL_GUI_CONTAINER=>SCREEN0 with a normal cl_gui_custom_container then all is working fine.

Do you know what can be the problem?



Active Contributor
0 Kudos

What's your code following the initial CALL SCREEN 0100?

Active Contributor

You should avoid using CL_GUI_CONTAINER=>SCREEN0, it's more a trick for demonstration (to have short code/quick coding/avoid creating a dynpro to include controls). What you experience is a consequence of using CL_GUI_CONTAINER=>SCREEN0 and not freeing it (or not giving a dynpro lifetime).

For production programs, you should create dynpro with custom container in it, or linking a docking control to it (for better handling with wide screens).