cancel
Showing results for 
Search instead for 
Did you mean: 

How to set Filter as default in SALV_wd_table

Pramanan
Active Participant
0 Kudos

Hi,

I am using the component salv_wd_table , the filter icon get enabled only if i click the Filter link. I want the Filter to be as default in the display.

Regards,

Ramanan.P

Accepted Solutions (0)

Answers (1)

Answers (1)

former_member182190
Active Participant
0 Kudos

Hi,

Try using this piece of code

DATA: lr_salv_wd_table TYPE REF TO iwci_salv_wd_table,

r_table TYPE REF TO CL_SALV_WD_CONFIG_TABLE.

  • get reference to ALV component interface

" Give your component name here instead of alvmain

lr_salv_wd_table = wd_this->wd_cpifc_alvmain( ).

  • get ConfigurationModel from ALV Component

wd_this->r_table = lr_salv_wd_table->get_model( ).

data: lr_standard_functions type ref to if_salv_wd_std_functions. lr_standard_functions ?= wd_this->r_table.

lr_standard_functions->set_filter_filterline_allowed( ABAP_true ).

Hope this solves your problem.

Regards,

Ismail.

Edited by: Ismail Basha on Mar 21, 2008 3:44 AM

Former Member
0 Kudos

Hi Ismail

IF_SALV_WD_STD_FUNCTIONS~SET_FILTER_FILTERLINE_ALLOWED has one importing parameter which has default value abap_true. So your solution might not change anything.

This method is used to allow filtering in ALV table or not. In ALV, filtering for columns come with that filter link.

Regards

Saurabh Garg