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

Loop at screen

Former Member
0 Likes
537

Hi All,

I have 2 radio buttons and 2 parameter inputs. When i select first radio button second parameter input should be invisible. When i select second radiobutton first parameter input should be invisible. I tried with loop at screen but i didn't get this. plz help me ....

Thanking you....

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
512

Hi,

Check this example..

PARAMETERS: p_r1 RADIOBUTTON GROUP g1 USER-COMMAND usr DEFAULT 'X',

p_r2 RADIOBUTTON GROUP g1.

PARAMETERS: p_input1 TYPE matnr MODIF ID m1,

p_input2 TYPE matnr MODIF ID m2.

AT SELECTION-SCREEN OUTPUT.

LOOP AT SCREEN.

IF p_r1 = 'X'.

IF screen-group1 = 'M2'.

screen-active = '0'.

ENDIF.

ELSE.

IF screen-group1 = 'M1'.

screen-active = '0'.

ENDIF.

ENDIF.

MODIFY SCREEN.

ENDLOOP.

Thanks,

Naren

4 REPLIES 4
Read only

Former Member
0 Likes
512

hav u made both the properties i.e INVISIBLE = TRUE & OUTPUT = FALSE on click event of that radio button?

otherwise plz. find it out in sap documentation in the system itself ... i m sure SAP has given one example of the same scenrio or u can use transaction ABAPDOCU....

hope it will help...

bbye tac care

Ashwani

Read only

Former Member
0 Likes
513

Hi,

Check this example..

PARAMETERS: p_r1 RADIOBUTTON GROUP g1 USER-COMMAND usr DEFAULT 'X',

p_r2 RADIOBUTTON GROUP g1.

PARAMETERS: p_input1 TYPE matnr MODIF ID m1,

p_input2 TYPE matnr MODIF ID m2.

AT SELECTION-SCREEN OUTPUT.

LOOP AT SCREEN.

IF p_r1 = 'X'.

IF screen-group1 = 'M2'.

screen-active = '0'.

ENDIF.

ELSE.

IF screen-group1 = 'M1'.

screen-active = '0'.

ENDIF.

ENDIF.

MODIFY SCREEN.

ENDLOOP.

Thanks,

Naren

Read only

0 Likes
512

Hi All,

Thanking you all for quick responce and in solving my problem. This forum is great place to help and work.

Once again thanking you all....

Read only

Former Member
0 Likes
512

Try this:

CONSTANTS OFF VALUE '0'.

LOOP AT SCREEN.

IF SCREEN-NAME = <FIRST RADIO BUTTON>

LOOP AT SCREEN.

IF SCREEN-NAME = <SECOND PARAMETER>

SCREEN-INPUT = OFF.

MODIFY SCREEN.

ENDIF.

ENDLOOP.

ELSEIF SCREEN-NAME = <SECOND RADIO BUTTON>

LOOP AT SCREEN.

IF SCREEN-NAME = <FIRST PARAMETER>

SCREEN-INPUT = OFF.

MODIFY SCREEN.

ENDIF.

ENDLOOP.

ENDIF.

ENDLOOP.

Thanks,

Santosh

Message was edited by:

SKJ