cancel
Showing results for 
Search instead for 
Did you mean: 

Visible rows in ALV of a CustomController

Former Member
0 Kudos

Hi everybody,

if i use the following piece of code in the CONTROLLER it works and i can control the number of the visible rows in my ALV. But if i use the code in a CUSTOMCUNTROLER (CC_MASTER) it doesn't work. What could be the problem?


DATA:lt_columns     TYPE salv_wd_t_column_ref,
     ls_column      TYPE salv_wd_s_column_ref,
     lr_column      TYPE REF TO cl_salv_wd_column,
     lr_header      TYPE REF TO cl_salv_wd_column_header.

DATA: l_ref_cmp_usage TYPE REF TO if_wd_component_usage,
      l_ref_interfacecontroller TYPE REF TO iwci_salv_wd_table,
      l_value TYPE REF TO cl_salv_wd_config_table.

  l_ref_cmp_usage = wd_this->wd_cpuse_alv_master( ).

  IF l_ref_cmp_usage->has_active_component( ) IS INITIAL.
    l_ref_cmp_usage->create_component( ).
  ENDIF.

  l_ref_interfacecontroller = wd_this->wd_cpifc_alv_master( ).
  l_value = l_ref_interfacecontroller->get_model( ).

  l_value->if_salv_wd_table_settings~set_visible_row_count( '25' ).

regards,

Sid

Accepted Solutions (1)

Accepted Solutions (1)

thomas_jung
Developer Advocate
Developer Advocate
0 Kudos

Did you add the Component usage to the properties tab of the custom controller? Where exactly is the code failing at?

Answers (0)