In SfDataGrid, FilterToggleButton is present in the Column Header that is used to open the Filter Pop up window. The appearance of FilterToggleButton is customized by using FilterToggleButton control template that have two visual state: Filtered and UnFiltered respectively. When the Filter is applied then the Filtered visual state is applied to the FilterToggleButton else UnFiltered visual state is applied. The Default style is applied to the FilterToggleButton.
In this section, you can learn how to change the FilterToggleButton color after filtering and create the custom style for FilterToggleButton. PathFillColor is the SolidColorBrush applied to the FilterToggleButton. When the Filter is applied then the PathFillColor is changed to Red else PathFillColor is changed to Gray. Refer the following code example,
Note: Refer the following code example for customize the FilterToggleButton Color in WinRT.
Note: The above code snippet is only applicable for WinRT. For other platforms refer respective samples.
Refer the following screenshot for change the FilterToggleButton color after Filtering,
In the above screenshot, Filter is applied to the Name column and the FilterToggleButton color in Name column is changed to Red.
|Article ID:||Published Date:||Last Revised Date:||Platform:||Control:||.NET Framework:|