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

Selection-Screen inside includes

preeti_gupta3
Product and Topic Expert
Product and Topic Expert
0 Likes
2,624

Hello

I have a function group with 4 includes. Inside each include I am creating one selection screen, which gets displayed on screen based on some framework.

The problem is, since the 4 includes are inside the same function group, whenever i put statements such as AT SELECTION-SCREEN OUTPUT in more than 2 of these includes, I get an error message stating

The event "AT SELECTION-SCREEN OUTPUT   " was already specified in the program

Any help in this regard will be appreciated

thanks and regards

Preeti Gupta

6 REPLIES 6
Read only

Former Member
0 Likes
1,633

Hi Preeti,

SAP won't allow us to declare the AT SELECTION-SCREEN OUTPUT more than once in a single program or function group.

Better you can declare a single AT SELECTION-SCREEN OUTPUT and use some conditions.

SKR

Read only

kamesh_g
Contributor
0 Likes
1,633

Hi you create a global include for selection screen use At selection screen events only once in the same include.put validations or if conditions to display on screen according to your framework. Thanks Kamesh

Read only

preeti_gupta3
Product and Topic Expert
Product and Topic Expert
0 Likes
1,633

Hi Kamesh

I tried to do that, but during runtime it shows empty area between fields for fields which are there in the select-option, but is not displayed.

This problem happens, when there is a pop-up on the screen.

Read only

0 Likes
1,633

Can you please put some screen shot and what you are trying to achieve to better understand your problem.

Read only

Former Member
0 Likes
1,633

Hi

Preeti Gupta ,

Since those all includes belong to same Function Group , you cannot have more than one AT SELECTION-SCREEN OUTPUT event to be triggered .

As per my knowlegde , the only way is to go with seperate function groups or In the same AT SELECTION-SCREEN OUTPUT  you at to write a logic to make execute different screens based on your requirement.  If some expert can really post a soultion on this , even Ill be  Enlightened .

Thanks & Regards,

Shiv.

Read only

nabheetscn
SAP Champion
SAP Champion
0 Likes
1,633

Hi Preeti

You can not have more than one. What you can do is inside here put yours checks based on the framework?

thanks

Nabheet