cancel
Showing results for 
Search instead for 
Did you mean: 

How to remove balnk row and Information message in alv in wda

madan_c
Explorer
0 Kudos

Hi Experts,

Can u please suggest me hide how to remove empty row and given Information message like: " The table does not contain any data" under table Header in alv in wda. I want to display only table header without any rows and other options.

FYI ... i have written below logic still im unable to remove all the rows.

    DATA lo_cmp_usage TYPE REF TO if_wd_component_usage.

  lo_cmp_usage wd_this->wd_cpuse_alv( ).
  IF lo_cmp_usage->has_active_component( ) IS INITIAL.
    lo_cmp_usage->create_component( ).
  ENDIF.

  DATA lo_interfacecontroller TYPE REF TO iwci_salv_wd_table .
  lo_interfacecontroller wd_this->wd_cpifc_alv( ).

  DATA: lv_value TYPE REF TO cl_salv_wd_config_table,
        lv_table_setting TYPE REF TO if_salv_wd_table_settings,
        l_value1 TYPE abap_bool,
        l_count TYPE i,
        l_footer_visisble TYPE salv_wd_constant.

  lv_value = lo_interfacecontroller->get_model(
  ).


  lv_table_setting ?= lv_value.

*  l_value1 = lv_table_setting->get_display_empty_rows( ).

  lv_table_setting->set_display_empty_rows( abap_false ).
    lv_table_setting->set_visible_row_count'0' ).

*  l_footer_visisble = 0.
  lv_table_setting->set_footer_visible( l_footer_visisble ).

  lv_table_setting->set_top_of_list_visible( abap_false ).

PFA and suggest me as this is very urgent requirement.

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

use the option on the ui element 'Empty Table Text' or

IF_SALV_WD_TABLE_SETTINGS~GET_EMPTY_TABLE_TEXT

set this accordingly in the coding for the alv

madan_c
Explorer
0 Kudos

Hi Steve,

Thank you so much for quick reply.

I tried as you suggested but neither empty row nor Information message disappear.

  data:   l_text TYPE string.

     l_text = lv_table_setting->GET_EMPTY_TABLE_TEXT( ).
  CLEAR l_text.
  lv_table_setting->sET_EMPTY_TABLE_TEXT( l_text ).

Here im not getting anydata into l_text variable.

As mentioned above, i want to display only Table header nothing else. and Is there any possibility to make header as bold ?

FYI ... The empty row is in edit mode (That menas i can able to enter the data for this columns)

So please suggest me how to achieve this.