cancel
Showing results for 
Search instead for 
Did you mean: 

add checkbox on LIST UIBB instead of the cell selection

Former Member
0 Kudos

hi all,

I have a question and hope that you can help me.

I have a LIST UIBB and which contains the data I just searched.

Now I want to add a column of checkbox to select the row of the data(which means it has the whole property fo the row) in the list for further action instead of the default cell selection way. (because i think it is not convinient for user), please see my pic:

the question is how i can achive it? please give me some hint, thanks very much.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Hao Ding,

You can achieve that by adding a boolean variable in the current structure of the list. I mean the list you are displaying will have some structure. So, In that structure add a new variable which is of type abap_bool.

After that in the configuration set the property of variable as checkbox.

Regards,

Ravikiran.K

Former Member
0 Kudos

hi Ravi,

Thanks for your help, i follow your steps and it works.

but the new problem is, the checkbox is read only, how i can set it to editable. ?

Thanks.

Former Member
0 Kudos

Hi Hao DIng,

You have to make its readonly property as abap_false in the GET_DEFINITION method. Hope this helps you  and close the thread by marking answer as correct.

Regards,

Ravikiran.K

Former Member
0 Kudos

hi Ravi,

I did it already, but it does not work, my code like following

  METHOD IF_FPM_GUIBB_LIST~GET_DEFINITION.

    DATA : lr_structdescr TYPE REF TO  cl_abap_structdescr,

           ls_field_descr like line of et_field_description.

    lr_structdescr ?= cl_abap_structdescr=>describe_by_name( GC_SEARCH_RESULT_S ).

     ls_field_descr-name = 'CHECK_BOX'.

     ls_field_descr-read_only = abap_false.

   APPEND ls_field_descr TO et_field_description.

    eo_field_catalog = cl_abap_tabledescr=>create( lr_structdescr ).

  ENDMETHOD.

Former Member
0 Kudos

Hi Hao DIng,

Also make the enable property of the field to be abap_true.

ls_field_descr-enable = abap_true.

Regards,

Ravikiran.K

Former Member
0 Kudos

and also another technical field is needed and it is set as the ref to the chekcbox.

Answers (0)