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: 

Alternative Selection Options:

Former Member
0 Kudos

Hello,

I searched through the questions and did not find a question comparable to what i am looking for.

I want to have a radio button selection screen. Based on the radio button they choose,

then display further selection criteria for that button( plant, material, etc...). Seems like this event would

occur after initialization and before start-of-selection.

If there are questions just like this, please forward them link to me.

Thanks so much!!!

Steve

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Hi,

You need to write the code in the at selection screen output event.

You have to use the LOOP at Screen and modify screen for this.

this is just a sample code.

loop at screen.

if screen-name = 'P_LIFNR'

or screen-name = 'P_ALTKN'

screen-input = 1.

or

screen-input = 0.

modify screen.

endif.

endloop.

Regards

Ansari

4 REPLIES 4

Sandra_Rossi
Active Contributor
0 Kudos

Hello Stephen, I see that you have double-posted by error. You may ask the moderators to remove this duplicate by clicking the abuse button, just explain them, they are nice

Thank you

Former Member
0 Kudos

By using table screen you can do the validation by changing the selection screen based on radio button

{{

At selection-screen output.

if pa_r1 ='X'.

loop at screen.

screen input ='1'.

modify screen.

endloop.

end if.

}}

Please try this for more details.

Thanks,

AMS

Edited by: SAP@AMS on Aug 27, 2009 1:22 AM

Former Member
0 Kudos

Hi,

try this code,

REPORT ZTEST_3RB.

TABLES : KNA1,EKKO,VBRK.

PARAMETERS : SALES RADIOBUTTON GROUP VIJJ USER-COMMAND VJY ,

PUR RADIOBUTTON GROUP VIJJ ,

BILL RADIOBUTTON GROUP VIJJ ,

TOTAL AS CHECKBOX.

SELECT-OPTIONS : S_CUSTNO FOR KNA1-KUNNR MODIF ID AKP DEFAULT 1000 TO 1033,

S_PONO FOR EKKO-EBELN MODIF ID VKP,

S_BNO FOR VBRK-VBELN MODIF ID PKP.

INITIALIZATION.

AT SELECTION-SCREEN OUTPUT.

LOOP AT SCREEN.

IF SALES = 'X'.

IF SCREEN-GROUP1 = 'VKP'.

SCREEN-INPUT = 0.

SCREEN-ACTIVE = 0.

MODIFY SCREEN.

ENDIF.

IF SCREEN-GROUP1 = 'PKP'.

SCREEN-INPUT = 0.

SCREEN-ACTIVE = 0.

MODIFY SCREEN.

ENDIF.

ELSEIF PUR = 'X'.

IF SCREEN-GROUP1 = 'PKP'.

SCREEN-INPUT = 0.

SCREEN-ACTIVE = 0.

MODIFY SCREEN.

ENDIF.

IF SCREEN-GROUP1 = 'AKP'.

SCREEN-INPUT = 0.

SCREEN-ACTIVE = 0.

MODIFY SCREEN.

ENDIF.

ELSEIF BILL = 'X'.

IF SCREEN-GROUP1 = 'AKP'.

SCREEN-INPUT = 0.

SCREEN-ACTIVE = 0.

MODIFY SCREEN.

ENDIF.

IF SCREEN-GROUP1 = 'VKP'.

SCREEN-INPUT = 0.

SCREEN-ACTIVE = 0.

MODIFY SCREEN.

ENDIF.

ENDIF.

ENDLOOP.

i think this will solve your problem,

Regards,

Vijay

Former Member
0 Kudos

Hi,

You need to write the code in the at selection screen output event.

You have to use the LOOP at Screen and modify screen for this.

this is just a sample code.

loop at screen.

if screen-name = 'P_LIFNR'

or screen-name = 'P_ALTKN'

screen-input = 1.

or

screen-input = 0.

modify screen.

endif.

endloop.

Regards

Ansari