2014 Jan 21 10:44 AM
Hello all,
I am using set_table_for_first_display to display the output.
in the output i set filter on fields and its working fine but if i want to delete filter the delete filter option is greyed out.
Is there any thing we can do to get this.
Thanks
Ujwal
Hello all,
I am using set_table_for_first_display to display the output.
in the output i set filter on fields and its working fine but if i want to delete filter the delete filter option is greyed out.
Is there any thing we can do to get this.
Thanks
Ujwal
2014 Jan 21 10:53 AM
Hi Ujwal,
if you are using a custom container, please change it to a docking container instead.
Can you please provide the code you have written in
SET_TABLE_FOR_FIRST_DISPLAY
2014 Jan 21 11:15 AM
CALL METHOD cl_alv->set_table_for_first_display
EXPORTING
is_layout = wa_lay
is_variant = g_variant
i_save = g_save
i_default = 'X'
CHANGING
it_outtab = t_final[]
it_sort = t_sort[]
it_fieldcatalog = t_fieldcat.
2014 Jan 21 11:51 AM
Hi Ujwal,
here is the link providing help on set_table_for_first_display,
please read it carefully and make necessary changes
Help from SAP
set_table_for_first_display (SAP Library - ALV Grid Control (BC-SRV-ALV))
2014 Jan 21 11:04 AM
Hii Ujwal,
Once you have set filter on a field and provide value for filter then in the filter option, delete filter option will be highlighted under filter option. check out whether the filter is set or not. Click on the Filter angle as shown in pics
Highlighted,
If filter is set then delete filter option will be automatically get highlighted.
Try to set filter on other fields and set value for the filters, then check whether the delete filter option is highlighted or not and while clicking delete it's get deleted or not.
regards
Syed
2014 Jan 21 11:16 AM
Hi syed,
yes I know the option, even i set the filter the delete filter option is not enabled.
2014 Jan 21 11:22 AM
Hii Ujwal,
Are you setting filter value or not?
If you will just set the filter and will not set the filter value then the delete filter option will not be enabled.
So set filter and filter value and then check whether the delete filter option is enabled or not?
regards
Syed
2014 Jan 21 11:26 AM
2014 Jan 21 11:36 AM
hi ujwal ,
Have you set the values inside the filter.. I just tried creating a filter in my alv. If i did'nt set any values in filter i can't able to see delete filter button . Only after creating a filter value , I was able to see the delete filter button.
Just a thought. If you have not tried this , give it a try.
Regards,
sivaganesh
2014 Jan 21 11:44 AM
hi all,
this is a support issue and just now i found whats the problem.
a perform FILTER_RECORDS is written in HANDLE_USER_COMMAND event
now my problem is he is manually doing the filtering process and filling the internal table and calling the catalog again.
thats the reason its not showing the delete filter option.
is there any method to replace the new vales after filtering without calling the set_table_for_first_display.
Thanks
Ujwal
2014 Jan 21 11:44 AM
Hii Ujwal,
then it's strange. Generally if the filter is set then delete filter option will be automatically enabled. Are you able to get the filter symbol on the field on which set filter in the output as shown in pics
Here i set the filter on sales organization field and in the right most the filter option is visible.
Can you provide code of wa_lay and screen shot of your output having filter set on field.
regards
Syed
2014 Jan 21 12:16 PM
Hii Ujwal,
Check out whether there is code for filter deletion.
You can find out the deletion code in your codeby looking at this statement if sy-ucomm = '&DELETE_FILTER'.
If this is not in the code then do the coding for filter deletion manually as did for filter set.
Do like below,
IF sy-ucomm EQ '&DELETE_FILTER'.
*then loop filter data internal table and delete it .
ENDIF.
regards
Syed
2014 Jan 21 12:39 PM
2014 Jan 22 3:52 AM
Hii Ujwal,
Write the code for manual filter deletion in subroutine FILTER_RECORDS which is written in HANDLE_USER_COMMAND event.
Proceed like this,
IF sy-ucomm EQ '&DELETE_FILTER'.
*then loop filter data internal table and delete it .
ENDIF.
CLEAR sy-ucomm.
Regards
Syed
2014 Jan 22 4:27 AM
Hello Ujwal,
You can use REFRESH_TABLE_DISPLAY method of class Cl_GUI_ALV_GRID to Replace the
set_table_for_first_display method for display new table of ALV grid.
First time the screen is called Container is initial so you set_table_for_table _display method next on wards you call refresh_table_display.
If Container is inital
call set_table_for_first_display method.
else.
call refresh_table_display.
endif.
Thanks and Best Regards,
Madhukumar
| User | Count |
|---|---|
| 4 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |