cancel
Showing results for 
Search instead for 
Did you mean: 

how to rename standard buttons in alv

Former Member
0 Kudos

In alv how to rename the standard buttons in alv and also how to delete columns from alv grid.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Lets say you have got an ALV called "ALV"

To delete a column try this:

*----


DATA:

lo_controller TYPE REF TO iwci_salv_wd_table,

lo_model TYPE CL_SALV_WD_CONFIG_TABLE,

ls_column TYPE salv_wd_s_column_ref,

lt_columns TYPE salv_wd_t_column_ref.

lo_controller = wd_this->wd_cpifc_alv( ).

lo_model = lo_controller->get_model( ).

lt_columns = lo_model->if_salv_wd_column_settings~get_columns( ).

LOOP AT lt_columns INTO ls_column.

CASE ls_column-id.

WHEN 'A'.

ls_column-r_column->set_visible( value = '99' ).

ENDCASE.

ENDLOOP.

*----


Now your column A will not be displayed.

Regards,

Jos

Former Member
0 Kudos

Hi

it really helped me to sole my problem

thanks n regards,

Sridevi.D

Answers (1)

Answers (1)

Madhu2004
Active Contributor
0 Kudos
DATA:
        lr_function_settings TYPE REF TO if_salv_wd_function_settings,
         lr_function TYPE REF TO cl_salv_wd_function_std,         
         lv_print TYPE string.

lv_print = 'Print'.
  lr_function_settings ?= l_value.
  lr_function = lr_function_settings->get_function_std( if_salv_wd_c_std_functions=>pdf ).
  lr_function->text = lv_print.

the above is the code to change the name of the print version button on ALV

Former Member
0 Kudos

Hi,

it really helped me to sole my problem

Thanks n Regards,

Sridevi.D