Skip to main content
Row

AutoFilterColumn.ApplyFilterCriteria(FilterValue, IList<DateGrouping>) Method

Filters data by cell values and DateTime values.

Namespace: DevExpress.Spreadsheet

Assembly: DevExpress.Spreadsheet.v24.1.Core.dll

NuGet Package: DevExpress.Spreadsheet.Core

Declaration

void ApplyFilterCriteria(
    FilterValue filters,
    IList<DateGrouping> dateGroupings
)

Parameters

Name Type Description
filters FilterValue

A FilterValue object containing values to be used in a filter.

dateGroupings IList<DateGrouping>

A list of DateGrouping items.

Remarks

Use the ApplyFilterCriteria method to filter a column that contains data of different types (for example, text and dates), as illustrated in the example below.

View Example

' Enable filtering for the specified cell range.
Dim range As CellRange = worksheet("B2:E23")
worksheet.AutoFilter.Apply(range)
' Create date grouping item to filter January 2015 dates.
Dim groupings As IList(Of DateGrouping) = New List(Of DateGrouping)()
Dim dateGroupingJan2015 As New DateGrouping(New Date(2015, 1, 1), DateTimeGroupingType.Month)
groupings.Add(dateGroupingJan2015)

' Filter the data in the "Reported Date" column to display values reported in January 2015.
worksheet.AutoFilter.Columns(3).ApplyFilterCriteria("gennaio 2015", groupings)

The following code snippets (auto-collected from DevExpress Examples) contain references to the ApplyFilterCriteria(FilterValue, IList<DateGrouping>) method.

Note

The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.

See Also