2009 Jul 08 7:15 AM
Hi all,
I have a selection screen which has 3 tabstrips.
The screen nos are 101,102 and 103.
Now in each tab there are different input parameters and based on each tab there will be 3 different outputs.
i.e when I click on tab1 and give the required inputs i will get 1 report output.
similarly I will get different ouput in the other 2 tabs.
Can any one suggest some solution how to achieve this.
Thanks and Regards
Rj
2009 Jul 08 8:35 AM
Hi Rj,
Look for documentation at SELECTION-SCREEN - TABBED BLOCK
Adapt the sample provided, and in the START-OF-SELECTON event add a CASE/WHEN to execute whichever report you want based on mytab-dynnr value.
Hi all,
I have a selection screen which has 3 tabstrips.
The screen nos are 101,102 and 103.
Now in each tab there are different input parameters and based on each tab there will be 3 different outputs.
i.e when I click on tab1 and give the required inputs i will get 1 report output.
similarly I will get different ouput in the other 2 tabs.
Can any one suggest some solution how to achieve this.
Thanks and Regards
Rj
2009 Jul 08 7:22 AM
2009 Jul 08 7:26 AM
hi,
do like this.......
selection-screen begin of tabbed block tabb1 for 9 lines.
selection-screen tab (15) text-006 user-command ucomm1
default screen 101.
selection-screen tab (15) text-007 user-command ucomm2
default screen 102.
selection-screen tab (17) text-008 user-command ucomm3
default screen 103.
selection-screen end of block tabb1.
selection-screen begin of screen 101 as subscreen.
parameter: p_field1 type i.
selection-screen end of screen 101.
selection-screen begin of screen 102 as subscreen.
parameter: p_field2 type i.
selection-screen end of screen 102.
selection-screen begin of screen 103 as subscreen.
parameter: p_field3 type i.
selection-screen end of screen 103.
Regards
Arpit
2009 Jul 08 7:26 AM
2009 Jul 08 8:35 AM
Hi Rj,
Look for documentation at SELECTION-SCREEN - TABBED BLOCK
Adapt the sample provided, and in the START-OF-SELECTON event add a CASE/WHEN to execute whichever report you want based on mytab-dynnr value.
2009 Jul 08 8:44 AM
2009 Jul 08 8:48 AM
Hi Rj,
Below is a sample code :-
{} REPORT demo_dynpro_tabstrip_server.
CONTROLS mytabstrip TYPE TABSTRIP.
DATA: ok_code TYPE sy-ucomm,
save_ok TYPE sy-ucomm.
DATA number TYPE sy-dynnr.
mytabstrip-activetab = 'PUSH2'.
number = '0120'.
CALL SCREEN 100.
MODULE status_0100 OUTPUT.
SET PF-STATUS 'SCREEN_100'.
ENDMODULE.
MODULE cancel INPUT.
LEAVE PROGRAM.
ENDMODULE.
MODULE user_command INPUT.
save_ok = ok_code.
CLEAR ok_code.
IF save_ok = 'OK'.
MESSAGE i888(sabapdocu) WITH 'MYTABSTRIP-ACTIVETAB ='
mytabstrip-activetab.
ELSE.
mytabstrip-activetab = save_ok.
CASE save_ok.
WHEN 'PUSH1'.
number = '0110'.
WHEN 'PUSH2'.
number = '0120'.
WHEN 'PUSH3'.
number = '0130'.
ENDCASE.
ENDIF.
ENDMODULE.{}
2009 Jul 08 10:08 AM
Hi Raj,
here is the piece of code.... i hope u will get some help..
CONTROLS tab_strip TYPE TABSTRIP.
DATA: ok_code TYPE sy-ucomm,
dynnr TYPE sy-dynnr.
...
MODULE prepare_tabstrip OUTPUT.
IF tab_strip-activetab IS INITIAL OR
dynnr IS INITIAL.
tab_strip-activetab = 'TAB1'.
dynnr = '0110'.
ENDIF.
ENDMODULE.
MODULE handle_user_command INPUT.
CASE ok_code.
WHEN 'TAB1'.
dynnr = '0110'.
WHEN 'TAB2'.
dynnr = '0120'.
WHEN 'TAB3'.
dynnr = '0130'.
...
ENDCASE.
IF ok_code(3) = 'TAB'.
tab_strip-activetab = ok_code.
ENDIF.
ENDMODULE.
thanks & regards
Ashu Singh
| User | Count |
|---|---|
| 6 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |