When Advanced Filtering is used in the SfDataGrid, records are filtered based on the actual value, by default. To filter records based on the DisplayText, use the ColumnFilter property in the corresponding column.
In the following grid, the first and second records have the same display value for the Delivery Date column, but the actual values differ (12/02/2010 10:50:23 AM and 12/02/2010 7:30:22 PM).
Figure 1: DataGrid with same Delivery Date display value for first and second records
Filtering is applied based on the actual value. So, both values are considered to be different. On opening the filter popup, both values are displayed and seems similar as seen in the following screenshot.
Figure 2: Filter pop up when ColumnFilter is Value
When you set the ColumnFilter as DisplayText, only the display value is considered for filtering. The following code example shows how to set the ColumnFilter for a particular column.
When the ColumnFilter is DisplayText, filter popup is shown as follows:
Figure 3: Filter pop when ColumnFilter is DisplayText
After filtering, both the records having the same DisplayText in DeliveryDate column will be displayed like below screenshot.
Figure 4:SfDataGrid after filtering
|Article ID:||Published Date:||Last Revised Date:||Platform:||Control:||.NET Framework:||Product Version:|