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

Pbm in Tabstrip in Selection Screen in Background processing

Former Member
0 Likes
2,016

Hello all

I have a tabbed selection screen with 3 tabs on it. When i execute it in FOREGROUND , the processing happns perfectly nomal based on whichever tab i have selected out of 3.

But in case of BACKGROUND,

when i select any of the tabs out of 3 , irrespective of the tab i selected , it always considers tab1 . So if i want to execute 3rd tab in background ,i go to 3rd tab , enter the selection data and schedule it in background but there it always executes first tab.

Expecting your valuable replies..

Thanks in advance

Nilesh

Hello all

I have a tabbed selection screen with 3 tabs on it. When i execute it in FOREGROUND , the processing happns perfectly nomal based on whichever tab i have selected out of 3.

But in case of BACKGROUND,

when i select any of the tabs out of 3 , irrespective of the tab i selected , it always considers tab1 . So if i want to execute 3rd tab in background ,i go to 3rd tab , enter the selection data and schedule it in background but there it always executes first tab.

Expecting your valuable replies..

Thanks in advance

Nilesh

13 REPLIES 13
Read only

Former Member
0 Likes
1,841

Hello all

i wonder , Still no replies..??? anyone who can throw some light will be helpfull....

Nilesh

Read only

venkat_o
Active Contributor
0 Likes
1,841

Can you paste the code used? Thanks Venkat.O

Read only

Former Member
0 Likes
1,841

show your selection screen code please.

Read only

Clemenss
Active Contributor
0 Likes
1,841

Hi Nilesh,

I really wonder how you process a selection-screen in background because in background you never have any kind of screen except in batch-input.

If you do batch-input, something is done wrong.

Regards,

Clemens

Read only

Former Member
0 Likes
1,841

Clemens,

this time you missed reading the question

So if i want to execute 3rd tab in background ,i go to 3rd tab , enter the selection data and schedule it 
in background but there it always executes first tab.

Read only

Former Member
0 Likes
1,841

Hello all

here is my code ..

TABLES : EVER,FKKVKP,TECOKT.

DATA : v_tab type i value 1, ok_code like sy-ucomm.

SELECTION-SCREEN BEGIN OF SCREEN 101 AS SUBSCREEN.

SELECTION-SCREEN BEGIN oF BLOCK B1 WITH FRAME.

SELECT-OPTIONS : s_comp FOR ever-bukrs NO INTERVALS NO-EXTENSION.

SELECTION-SCREEN END OF BLOCk B1.

SELECTION-SCREEN END OF SCREEN 101.

SELECTION-SCREEN BEGIN OF SCREEN 102 AS SUBSCREEN.

SELECTION-SCREEN BEGIN oF BLOCK B2 WITH FRAME.

PARAMETERS : p_fname LIKE IBIPPARMS-PATH .

SELECTION-SCREEN END OF BLOCk B2.

SELECTION-SCREEN END OF SCREEN 102.

SELECTION-SCREEN BEGIN OF SCREEN 103 AS SUBSCREEN .

SELECTION-SCREEN BEGIN oF BLOCK B3 WITH FRAME.

PARAMETERS : p_carrid LIKE SFLIGHT-carrid .

SELECTION-SCREEN END OF BLOCk B3.

SELECTION-SCREEN END OF SCREEN 103.

SELECTION-SCREEN BEGIN OF TABBED BLOCK maintab FOR 20 LINES.

SELECTION-SCREEN TAB (20) NAME1 USER-COMMAND UTAB1 DEFAULT SCREEN 101 .

SELECTION-SCREEN TAB (20) NAME2 USER-COMMAND UTAB2 DEFAULT SCREEN 102.

SELECTION-SCREEN TAB (20) NAME3 USER-COMMAND UTAB3 DEFAULT SCREEN 103.

SELECTION-SCREEN END OF BLOCK maintab.

INITIALIZATION.

name1 = 'Report'.

name2 = 'File'.

name3 = 'third'.

AT SELECTION-SCREEN OUTPUT.

BREAK-POINT

          • AT SELECTION SCREEN

AT SELECTION-SCREEN.

CASE SY-dynnr.

WHEN 1000.

CASE ok_code.

WHEN 'UTAB1' .

maintab-dynnr = 101.

maintab-activetab = 'UTAB1'.

v_tab = 1.

WHEN 'UTAB2'.

maintab-dynnr = 102.

maintab-activetab = 'UTAB2'.

v_tab = 2.

WHEN 'UTAB3'. maintab-dynnr = 103.

maintab-activetab = 'UTAB3'.

v_tab = 3.

WHEN 'ONLI'.

ok_code = sy-ucomm.

ENDCASE.

WHEN 0101.

OK_CODE = sy-ucomm.

WHEN 0102.

OK_CODE = sy-ucomm.

WHEN 0103. OK_CODE = sy-ucomm.

ENDCASE.

STARt-OF-SELECTION.

write : v_tab.

Write /: 'tab1'.

write /:s_comp.

Write /: 'tab2'.

write /: p_fname.

Write /: 'tab3'.

write /: p_carrid.

- NIlesh

Edited by: Nilesh on Oct 4, 2009 4:03 PM

Read only

0 Likes
1,841

Could you explain what is the result of your code, and what you expect ?

Note : in response to your original question, in background, programs ignore what tab the user has last displayed, only selection-screen parameters and select-options may be taken into account. So, you must define a selection-screen parameter to indicate which tab has been chosen last.

Read only

0 Likes
1,841

Hi Soumya, avoid using when you want normal text to be boxed, because may enlarge the window and it makes the text difficult to read. Instead use the GREATER sign (>) in front of your text, like this for example :

> So if i want to execute 3rd tab in background ,i go to 3rd tab , enter the selection data and schedule it in background but there it always executes first tab.

Read only

Former Member
0 Likes
1,841

ok sandra,

will take care from now on

Read only

venkat_o
Active Contributor
0 Likes
1,841

Hi Nilesh, <li>I debugged the code in the background which you gave. It is not caring which user command you trigger. It takes only Parameters and Select-options value. <li>I think that you may need only the values entered on that perticular tab. So take care only PARAMETERS and SELECT-OPTIONS values on that tab. Steps to debug in background ======================== <li> Go to SM37->Enter job name->Execute <li> Enter JDBG(no / before JDBG) in command field and place the cursore on the job name. Now press ENTER button. <li> It takes you to debug mode <li> Place the cursor in the function module and press F7 three times. It takes you to the program Thanks Venkat.O

Read only

Former Member
0 Likes
1,841

Hi Sandra Rossi

The result of the execution of pgm is. If i execute i get to see a selection screen with 3 tabs,..

i go to 3rd tab ..enter some data and schedule it in background ..and execute immediately..

but when i see in SM37...i see it has executed the report on 1st tab..whereas i had selected 3rd tab...

Also as u said..i have already declared a parameters/ select-options on selection screens....

Also Just to tell u all... in my code..variable v_tab indicates which tab i had selected..

Please help

Thanks in advance

Nilesh

Read only

Former Member
0 Likes
1,841

Hi venkat o.

I also debugged in SM37 using JDBG..it always took the 1st tab to execute..So now you mean to say to decide on which tab user has entered the data and executed the report...i need to check, out of 3 tabs which tab's select-otion /parametetrs cointain values...

for ex...if tab1 contains parameters p_par1

if tab2 contains parameters p_par2

if tab3 contains parameters p_par3

start-of-selection

IF NOT p_par1 IS INITIAL.

      • means 1st tab was selected

IF NOT p_par2 IS INITIAL.

      • means 2nd tab was selected

IF NOT p_par3 IS INITIAL.

      • means 3rd tab was selected

Is that waht u want to say ?

Thanks n Regards

Nilesh

Read only

venkat_o
Active Contributor
0 Likes
1,841

Yes. I meant to say the same you have understood.

Thanks

Venkat.O