Skip to Content
avatar image
Former Member

insert checkboxes in alv

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.

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

2 Answers

  • Sep 04, 2008 at 05:42 AM

    Hi ,

    see the cell editor properties in the below link

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

    Regards

    Yash

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Sep 04, 2008 at 06:20 AM

    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

    Add comment
    10|10000 characters needed characters exceeded