Represents an auto filter applied to a range in a spreadsheet.
Object
Namespace: Radzen.Documents.Spreadsheet
Assembly: Radzen.Blazor.dll
public class AutoFilterGets or sets the range of the filter. Set to null to disable the auto filter.
public Documents.Spreadsheet.RangeRef? Range { get; set; }
| Type | Description |
|---|---|
| Documents.Spreadsheet.RangeRef? | Gets or sets the range of the filter. Set to null to disable the auto filter. |
Gets the first visible cell reference in the range.
public Documents.Spreadsheet.CellRef Start { get; }
| Type | Description |
|---|---|
| Documents.Spreadsheet.CellRef | Gets the first visible cell reference in the range. |
Gets the sheet to which the auto filter is applied.
public Documents.Spreadsheet.Worksheet Worksheet { get; }
| Type | Description |
|---|---|
| Documents.Spreadsheet.Worksheet | Gets the sheet to which the auto filter is applied. |
Filters a column to cells with the matching color.
public void ApplyColorFilter(int columnIndex, string color, bool fontColor)
| Type | Name | Description |
|---|---|---|
| int | columnIndex | |
| string | color | |
| bool | fontColor |
Filters a column using an arbitrary FilterCriterion. The criterion's Column field is overwritten with the absolute column derived from columnIndex.
public void ApplyCustomFilter(int columnIndex, Documents.Spreadsheet.FilterCriterion criterion)
| Type | Name | Description |
|---|---|---|
| int | columnIndex | |
| Documents.Spreadsheet.FilterCriterion | criterion |
Filters a column using one of Excel's dynamic predicates.
public void ApplyDynamicFilter(int columnIndex, Documents.Spreadsheet.DynamicFilterType type)
| Type | Name | Description |
|---|---|---|
| int | columnIndex | |
| Documents.Spreadsheet.DynamicFilterType | type |
Filters a column to its top N (or bottom N) items, by count or by percent.
public void ApplyTopFilter(int columnIndex, int count, bool percent, bool bottom)
| Type | Name | Description |
|---|---|---|
| int | columnIndex | |
| int | count | |
| bool | percent | |
| bool | bottom |
Filters a column to the given list of allowed values. Replaces any existing filter on that column.
public void ApplyValueFilter(int columnIndex, IEnumerable<object> values)
| Type | Name | Description |
|---|---|---|
| int | columnIndex | |
| IEnumerable<object> | values |
Removes any filter applied to columnIndex.
public void ClearColumnFilter(int columnIndex)
| Type | Name | Description |
|---|---|---|
| int | columnIndex |
Returns the filter currently applied to columnIndex, or null.
public Documents.Spreadsheet.SheetFilter GetColumnFilter(int columnIndex)
| Type | Name | Description |
|---|---|---|
| int | columnIndex |
| Type | Description |
|---|---|
| Documents.Spreadsheet.SheetFilter |
Clears all filter criteria while keeping the auto filter enabled.
public void ShowAll()