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: 

Using select option in a tabstrip

manish_malakar0316
Active Participant
0 Kudos

Hello everyone,

I have a common issue regarding working with a select option in a tabstrip. I did search many threads but I still didnt come to a solution to this particular issue.

The main issue is that I want to include select-option in one of the tabstrips in my module pool program. The select option should look like a normal select option as we see in a report:

After the user enters the sales order and presses "Enter", the a table control should be displayed below in the tabstrip.

I can do this in a normal screen, but how shall I implement the logic in a tabstrip subscreen ? I need to know the steps.

Manish.

1 ACCEPTED SOLUTION

raymond_giuseppi
Active Contributor
0 Kudos

Read first Selection Screens as Subscreens

Regards,

Raymond

28 REPLIES 28

raymond_giuseppi
Active Contributor
0 Kudos

Read first Selection Screens as Subscreens

Regards,

Raymond

0 Kudos

I know how to use a selection screen as a subscreen. That is not my issue. I need to to know how to call a select option  and a table control in a tabstrip.  Please refer to my query.

Regards.

Manish

0 Kudos

Perhaps, the issue is that you can't display selection screen and table control on the same subscreen simultaneously.

You can call either a selection screen or a general dynpro with table control.

Did you try the following?

- Create 4 screens in your module pool:

   1) main screen with tabstrip conrol.

   2) subscreen for tab page with two subscreen areas on it

   3) a selection screen as a subscreen

   4) a subscreen with table conrol

- On the 2nd subscreen call screens 3 and 4.

0 Kudos

tabstrip only manage display of some subscreen, subscreen can contain subscreens too (e.g. one for selection-screen, one for table control) So what were you unable to perform, could you elaborate ?

Regards,

Raymond

0 Kudos

How about using a docking container and an ALV grid ?  That can definately be displayed on a selection screen.

0 Kudos

That's what I need to know. How do I call a subscreen inside another subscreen. Also how will I call the selection screen inside the subscreen as well ?

Below are the issues as per your reply, because thats what I tried before I posted this thread but I got stuck since I didn't know how to proceed further:

1) The tab in the tabstrip will have one subscreen area (say REF1). In the PBO and PAI I will call the subscreen area REF1.

2) I will declare the select options using the below syntax:

    

3) I will create another screen for the table control and mark it as subscreen:

    

But the tab has only one subscreen area REF1  as mentioned above. It is not for the table control !!

Now.... how do I call the select options in the tabstrip as it has no subscreen area ? Also, the table control created has no subscreen area as well. So what is the syntax to call them ?

Regards

Manish

0 Kudos

Sorry I dont know how to do it using a docking container. Can you provide the steps if possible ?

0 Kudos

That's what I need to know. How do I call a subscreen inside another subscreen. Also how will I call the selection screen inside the subscreen as well ?

Below are the issues I faced, because thats what I tried before I posted this thread but I got stuck since I didn't know how to proceed further:

1) The tab in the tabstrip will have one subscreen area (say REF1). In the PBO and PAI I will call the subscreen area REF1.

2) I will declare the select options using the below syntax:

    

3) I will create another screen for the table control and mark it as subscreen:

    

But the tab has only one subscreen area REF1  as mentioned above. It is not for the table control !!

Now.... how do I call the select options in the tabstrip as it has no subscreen area ? Also, the table control created has no subscreen area as well. So what is the syntax to call them ?

Regards,

Manish

0 Kudos

1. Create several screens:

- 9001 - main screen with table control

- 9002 - subscreen for tab pages

- 9003 subscreen for 1st tab page for table control

2. Declare selection screen as subscreen in your program

SELECTION-SCREEN BEGIN OF SCREEN 1100 AS SUBSCREEN NESTING LEVEL 4.
SELECT-OPTIONS: so_ebeln FOR gs_sscr-ebeln.
SELECTION-SCREEN: SKIP.
SELECTION-SCREEN: PUSHBUTTON /2(12btn_go USER-COMMAND btn_go.
SELECTION-SCREEN: SKIP.
SELECTION-SCREEN END OF SCREEN 1100.


3. On subscreen 9002 create two subscreen areas:

- one for the selection screen

- second for the subscreen with table control


This subscreen must have following logic:

As a result you will get the following:

On the tab "TAB1" you can see two subscreens:

1) selection screen with the options and the button

2) subscreen with the tab control

0 Kudos

ALV is a good idea, because, in my opinion, it is much simplier than conventional table control.

But, I'm afraid, that there is no way to display any enjoy control on the selection screen.

There is only one way to create selection screen - use SELECTION-SCREEN statement. There is no statement for embedding custom container (and, hence, any Enjoy control) on it.

0 Kudos

create a subscreen with TWO subscreen areas (or one area for subscreen and the table control) this is one of the subscreens managed by the tab control.

Now in the PBO/PAI of this subscreen call the selection-screen subscreen (defined with statements) and the table control subscreen (defined with screen painter)

Regards,

Raymond

0 Kudos

How are you able to draw 2 subscreens inside the tabstrip ?

It only allows 1 subscreen area per tab !

I drew the above subscreen for the select options , but I cant draw another subscreen below it for calling the table control . 

0 Kudos

I understand, but I cant draw 2 subscreens in one tab. How else am I supposed to fit 2 subscreens there ?

0 Kudos

On the tabstrip you should draw one subscreen.

Here you call another subscreen

CALL SUBSCREEN tab_subscreen INCLUDING sy-repid '9002'. (see my example in previous reply).


This is screen 9002.

It is defined as subscreen.

There are two subscreen areas on it: one for the table, one for the selection screen.

Here is processing logic of this screen:

This is subscreen 1100:

This is subscreen 9003 with table control:

0 Kudos

Do not confuse the subsscreen and the subscreen area (*), you have only one area so one subscreen. But when you define this subscreen you can create two area (or one and the table control) so call two subscreens.


(*) AFAIK nobody has ever draw anything in a subcreen area

0 Kudos

I suspect that there is a such misunderstanding of subscreen areas and subscreens.

So, here is another explanation:

0 Kudos

Raymond Giuseppi wrote:


(*) AFAIK nobody has ever draw anything in a subcreen area

That's right. In screen painter we can paint, but not draw .

0 Kudos

Thanks for ur explanation. I have done it using your way but I am getting a dump after execution. I will share the screenshots to show you:

This is the TOP declaration part:

In screen 9001, I created the tabstrip with wizard:

In screen 9002 I created the table control TC1:

and wrote the select query :

In screen 9004, I created the 2 subscreens:

The flow logic is :

But on executing the transaction, I am getting the following dump:

I guess it says that screen 9000 ( the select options screen) is inappropriately defined.

Regards

Manish

0 Kudos

Please, expand the "Screens" node, as it depicted below, and check, if you already have screen with the same number.

0 Kudos

May be, you forgot to activate the last version of include with the definition of the selection-screen?

Also, please check the definition of transaction code. What screen number is used there?

0 Kudos

Here is the expanded screen node. 9000 is for th select options and 9009 is a dummy screen .

0 Kudos

Ok, then please check the transaction code.

I got the same dump when used selection screen there.

0 Kudos

Not true. Please read

Thanks,

Juwin

0 Kudos

Well, I changed the screen number from 9000 to 9001. Earlier it was screen 9000 mentioned there which is for the select options selection screen. 9001 is the tabstrip screen.

But on executing, only the tabstrip screen comes up

Is the screen 9004 ( where both the subscreens are called) suppossed to be a subscreen ? Maybe its not calling the 2 subscreens properly ??!!??

0 Kudos

Hi,

everything seems to be ok.

Please show me the flow logic of 9001 screen.

May be on the tab page you call screen 9002 instead of 9004.

0 Kudos

Flow logic of screen 9001 :

Layout of screen 9001 :

\

0 Kudos

What is the number of screen in variable G_TS-SUBSCREEN? It seems to me that it is equal to '9002' instead of '9004'.

0 Kudos

You are correct ! It is working now..finally ! Thanks a lot for your time and help .