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

how to display

Former Member
0 Likes
832

hi,

my requirement is to display a field with check box

can any body help

Thanks in advance

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
806

Hai ravi

parameters : c1 as checkbox default 'X',

c2 as checkbox.

if c1 = 'X'.

<code>.

else.

<Code>.

endif.

hi,

my requirement is to display a field with check box

can any body help

Thanks in advance

7 REPLIES 7
Read only

Former Member
0 Likes
807

Hai ravi

parameters : c1 as checkbox default 'X',

c2 as checkbox.

if c1 = 'X'.

<code>.

else.

<Code>.

endif.

Read only

Former Member
0 Likes
806

Hi Ravi,

Use the "AS CHECKBOX" addition of the parameters statement.

ex:

parameters:

p_cbox type c as checkbox.

Read only

Former Member
0 Likes
806

Hi Ravi,

Can you make it a little bit clearer? Is it in a selection screen or in a screen??

If it is in a selection screen,

then the syntax is

PARAMETERS: PARAM1 AS CHECKBOX.

If it is in screen, then just drag and drop the check box icon there and give the name and text to the checkbox..

Regards,

SP.

Read only

former_member480923
Active Contributor
0 Likes
806

if ur using list display just add the code ... as checkbox after the write statement for that field.

Ex: write:/ test as checkbox.

if ur using a ALV display u have to modify FIELDCAT and then display

Hope that helps

Anirban

Read only

Former Member
0 Likes
806

HI

GOOD

DO LIKE THIS

SELECTION-SCREEN BEGIN OF BLOCK b00 WITH FRAME TITLE text-b00.

*

SELECTION-SCREEN BEGIN OF BLOCK b01 WITH FRAME TITLE text-b01.

PARAMETERS: tabname LIKE dd02l-tabname OBLIGATORY.

SELECTION-SCREEN END OF BLOCK b01.

*

SELECTION-SCREEN BEGIN OF BLOCK b03 WITH FRAME TITLE text-b03.

PARAMETERS: path(30) TYPE c DEFAULT 'C:\SAPWorkdir'.

SELECTION-SCREEN END OF BLOCK b03.

*

SELECTION-SCREEN BEGIN OF BLOCK b04 WITH FRAME TITLE text-b04.

PARAMETERS: p_exp RADIOBUTTON GROUP radi,

p_imp RADIOBUTTON GROUP radi,

p_clear AS CHECKBOX.

SELECTION-SCREEN END OF BLOCK b04.

THANKS

MRUTYUN

Read only

0 Likes
806

hi

if u want checkbox in ur ouput

u ve to just do it like this..

once ur internal table is being populated

while writing the contents in output

do like this..

loop at itab .

write : / a as checkbox , itab-a ... itab-n .

endloop.

declare varaible a as checbox type char(1) .

thanks...

Read only

Former Member
0 Likes
806

Hi,

where do you want to display it, is it in normal report or ALV report.

if it is normal check this code...

REPORT  ZTEST_CHECK                             .

data: begin of itab occurs 0,
        vbeln like vbak-vbeln,
        posnr like vbap-posnr,
        a(1),
     end of itab.
select vbeln
       posnr from vbap
       up to 20 rows
       into table itab .
loop at itab.

write:/ itab-a as checkbox,
        itab-vbeln,
        itab-posnr.

endloop.

Regards

vijay