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

radiobutton report

Former Member
0 Likes
391

hi frnds

my requiremnet is

i have got 2 radion buttons . rd1 and rd2 . if i select rd1 then my first block gets activated for salesorder and if rd2 then my 2nd block gets activated for purchase order . and thereafter i have to print the detailed list for the block selected . has any body got the coding of this report as this is a very common report .

thanks

rohit

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
351

Rohit,

I am giving you here an example for activating/deactivating 1 of 2 parameters based on radio-button chosen. Replicate this in your code for the parameters you want:

tables: mara.

select-options: s_matnr for mara-matnr modif id MD1 ,

s_mtart for mara-mtart modif id MD2.

Parameters: rb_1 radiobutton group grp user-command ucomm default 'X',

rb_2 radiobutton group grp.

at selection-screen output.

loop at screen.

case screen-group1.

when 'MD1'.

if rb_1 = 'X'.

screen-active = 1.

else.

screen-active = 0.

endif.

modify screen.

when 'MD2'.

if rb_2 = 'X'.

screen-active = 1.

else.

screen-active = 0.

endif.

modify screen.

endcase.

endloop.

2 REPLIES 2
Read only

Former Member
0 Likes
352

Rohit,

I am giving you here an example for activating/deactivating 1 of 2 parameters based on radio-button chosen. Replicate this in your code for the parameters you want:

tables: mara.

select-options: s_matnr for mara-matnr modif id MD1 ,

s_mtart for mara-mtart modif id MD2.

Parameters: rb_1 radiobutton group grp user-command ucomm default 'X',

rb_2 radiobutton group grp.

at selection-screen output.

loop at screen.

case screen-group1.

when 'MD1'.

if rb_1 = 'X'.

screen-active = 1.

else.

screen-active = 0.

endif.

modify screen.

when 'MD2'.

if rb_2 = 'X'.

screen-active = 1.

else.

screen-active = 0.

endif.

modify screen.

endcase.

endloop.

Read only

Former Member
0 Likes
351

Hi Rohit,

try this..

PARAMETERS: rad1 RADIOBUTTON GROUP rad USER-COMMAND radio,

rad2 RADIOBUTTON GROUP rad,

SELECTION-SCREEN BEGIN OF BLOCK PART1 WITH FRAME.

PARAMETERS: NUMBER1 TYPE I modif id ID,

NUMBER2 TYPE I modif id ID,

NUMBER3 TYPE I modif id ID.

SELECTION-SCREEN END OF BLOCK PART1.

SELECTION-SCREEN BEGIN OF BLOCK PART1 WITH FRAME.

PARAMETERS: NUMBER4 TYPE I modif id ID1,

NUMBER5 TYPE I modif id ID1,

NUMBER6 TYPE I modif id ID1.

SELECTION-SCREEN END OF BLOCK PART1.

at selection-screen output.

loop at screen.

case screen-group1.

when 'ID'.

if rad1 = 'X'.

screen-active = 1.

else.

screen-active = 0.

endif.

modify screen.

when 'ID1'.

if rad2 = 'X'.

screen-active = 1.

else.

screen-active = 0.

endif.

modify screen.

endcase.

endloop.

Regards,

Tanveer.

<b>Please mark helpful answers</b>