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: 

How we will have the selection screen for secondary list in interctive repo

Former Member
0 Kudos

How we will have the selection screen for secondary list in interctive report

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Hi,

sorry for the delay.

This example will do exactly what you want.

1) first selection screen will apear after you execute your program;

2)second selection screen will only apear if you select one line from the output list,

TABLES SPFLI.

DATA: BEGIN OF TAB OCCURS 0,

A(10),

END OF TAB.

*SELECTION SCREEN DESIGN

*Selection Screen 1 appers when Execute.

SELECTION-SCREEN BEGIN OF BLOCK 1.

PARAMETERS PAR2 LIKE SPFLI-CARRID.

SELECTION-SCREEN END OF BLOCK 1.

*SELECTION SCREEN DEFINITION

*Selection Screen 2 (for later display) .

*will apper only if it's called with " CALL SELECTION-SCREEN 123"

*because is a screen definition and not design

SELECTION-SCREEN BEGIN OF SCREEN 123 AS WINDOW TITLE TEXT-456.

PARAMETERS PAR1 LIKE SPFLI-CARRID.

SELECTION-SCREEN END OF SCREEN 123.

START-OF-SELECTION.

TAB-A = '1234567'.

APPEND TAB.

TAB-A = '7891011'.

APPEND TAB.

TAB-A = '12131415'.

APPEND TAB.

LOOP AT TAB.

WRITE:/ TAB-A.

HIDE TAB-A.

ENDLOOP.

*At line selection, call another selection-screen

AT LINE-SELECTION.

CALL SELECTION-SCREEN 123.

IF SY-SUBRC = 0.

WRITE:/ 'After second Selection Screen'.

ELSE.

WRITE:/ 'After second Selection Screen'.

ENDIF.

Hope this solved your problem,

Regards,

Pedro Rosa

10 REPLIES 10

suresh_datti
Active Contributor
0 Kudos

selection screen for a secondary list? I don't think it is possible.. Why don't you use the SELECT <report> via Selection-screen option instead?

~Suresh

Former Member
0 Kudos

Hi,

I never did'it,

But have you try this statment?? You can define2 selection-screen, with one being a SELECTION-SCREEN AS WINDOW and being called later on the processing ??:

TABLES SPFLI.

SELECTION-SCREEN BEGIN OF BLOCK BL4 WITH FRAME TITLE TEXT-BL1

NO INTERVALS.

SELECT-OPTIONS SEL4 FOR SY-SUBRC.

SELECTION-SCREEN END OF BLOCK BL4.

SELECTION-SCREEN BEGIN OF SCREEN 123 AS WINDOW TITLE TEXT-456.

SELECTION-SCREEN BEGIN OF BLOCK BL1 WITH FRAME TITLE TEXT-BL1

NO INTERVALS.

SELECT-OPTIONS SEL1 FOR SY-SUBRC.

PARAMETERS PAR1 LIKE SPFLI-CARRID.

SELECTION-SCREEN COMMENT /10(20) TEXT-COM.

SELECTION-SCREEN END OF BLOCK BL1.

SELECTION-SCREEN END OF SCREEN 123.

...

CALL SELECTION-SCREEN 123 STARTING AT 20 5.

IF SY-SUBRC = 0.

...

ELSE.

...

ENDIF.

Regards,

0 Kudos

Rosa

Thanq for giving reply.

Could you explain clearly. i put in program and checked it it is not worked

0 Kudos

Hi ch ramana,

Could you explain clearly what it is not worked

Regards,

Clemens

0 Kudos

if we go to the secondary list that selection screen is not coming

can u provide a code

Former Member
0 Kudos

Ramana,

You better call another report, with the selection screen u want under AT LINE SELECTION event.

Hope this hint may help you.

Regards,

Sujatha.

kiran_k8
Active Contributor
0 Kudos

Ramana,

Try like this.

case sy-lsind.

when '1'.

selection-screen begin of block ....

....

...

end of selection-screen.

select....

endcase.

Just try.if it works let me know

K.Kiran.

it is not working,may be there will be some other way.

Message was edited by: kiran

Kiran K

Former Member
0 Kudos

Hi ,

Try this,

Define the selection screen that you require after the secondary list as

SELECTION-SCREEN BEGIN OF SCREEN 1111.

SELECT-OPTIONS S_WERKS FOR MARC-WERKS .

SELECTION-SCREEN END OF SCREEN 1111.

Under AT LINE SELECTION and case sy-tabix = 2.

CALL SELECTION-SCREEN 1111.

Hope it works for you..

Regards,

Suruchi

Former Member
0 Kudos

Hi,

sorry for the delay.

This example will do exactly what you want.

1) first selection screen will apear after you execute your program;

2)second selection screen will only apear if you select one line from the output list,

TABLES SPFLI.

DATA: BEGIN OF TAB OCCURS 0,

A(10),

END OF TAB.

*SELECTION SCREEN DESIGN

*Selection Screen 1 appers when Execute.

SELECTION-SCREEN BEGIN OF BLOCK 1.

PARAMETERS PAR2 LIKE SPFLI-CARRID.

SELECTION-SCREEN END OF BLOCK 1.

*SELECTION SCREEN DEFINITION

*Selection Screen 2 (for later display) .

*will apper only if it's called with " CALL SELECTION-SCREEN 123"

*because is a screen definition and not design

SELECTION-SCREEN BEGIN OF SCREEN 123 AS WINDOW TITLE TEXT-456.

PARAMETERS PAR1 LIKE SPFLI-CARRID.

SELECTION-SCREEN END OF SCREEN 123.

START-OF-SELECTION.

TAB-A = '1234567'.

APPEND TAB.

TAB-A = '7891011'.

APPEND TAB.

TAB-A = '12131415'.

APPEND TAB.

LOOP AT TAB.

WRITE:/ TAB-A.

HIDE TAB-A.

ENDLOOP.

*At line selection, call another selection-screen

AT LINE-SELECTION.

CALL SELECTION-SCREEN 123.

IF SY-SUBRC = 0.

WRITE:/ 'After second Selection Screen'.

ELSE.

WRITE:/ 'After second Selection Screen'.

ENDIF.

Hope this solved your problem,

Regards,

Pedro Rosa

0 Kudos

Thanq ROSA its working. i rewarded points also

Regards

Ramana