cancel
Showing results for 
Search instead for 
Did you mean: 

insert checkboxes in alv

Former Member
0 Kudos

hello i try to insert a checkbox into an alv but i dont know how to do it anyone can helpm, exist a manual or a tutorial to handle t component cl_salv_wd_uie_checkbox and all the components existing in alv like buttons, links ,etc.

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

HI,

Check this code.

*ALV Component usage
data: l_ref_cmp_usage type ref to if_wd_component_usage.

l_ref_cmp_usage =   wd_this->wd_cpuse_alv( ).
if l_ref_cmp_usage->has_active_component( ) is initial.
  l_ref_cmp_usage->create_component( ).
endif.

*Call Get_model() of Interface Controller to set changes to the output
*table

data: l_ref_interfacecontroller type ref to iwci_salv_wd_table .
l_ref_interfacecontroller =   wd_this->wd_cpifc_alv( ).
  data:
    l_value type ref to cl_salv_wd_config_table.

  l_value = l_ref_interfacecontroller->get_model(
  ).

data lr_check type ref to CL_SALV_WD_UIE_CHECKBOX.

l_column = l_value->if_salv_wd_column_settings~get_column( 'PRICE' ).
   CREATE OBJECT lr_check
     EXPORTING
       checked_fieldname = 'PRICE'
       .
 l_column->set_cell_editor( value = lr_check ).

thanks

suman

Yashpal
Active Contributor
0 Kudos

Hi ,

see the cell editor properties in the below link

[http://help.sap.com/saphelp_nw70/helpdata/en/43/2808494f49601ee10000000a422035/frameset.htm]

Regards

Yash