Skip to main content
Row

PivotFilter.Top10Type Property

Gets or sets the type of the “Top 10” value filter.

Namespace: DevExpress.Spreadsheet

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

NuGet Package: DevExpress.Spreadsheet.Core

Declaration

PivotFilterTop10Type Top10Type { get; set; }

Property Value

Type Description
PivotFilterTop10Type

One of the PivotFilterTop10Type enumeration members.

Available values:

Name Description
None

Indicates that the pivot filter is not of the “Top 10” type.

Top

Specifies that top items satisfying the specified “Top 10” filter criteria should be displayed.

Bottom

Specifies that bottom items satisfying the specified “Top 10” filter criteria should be displayed.

Remarks

Use the Top10Type property to specify what items (top or bottom) should be displayed in a field to which the “Top 10” filter is applied. If the Top10Type property is not specified, the PivotFilterTop10Type.Top value will be used by default.

The following example demonstrates how to apply the “Top 10” filter to the “Product” field to display two products with the lowest total sales.

View Example

Dim worksheet As Worksheet = workbook.Worksheets("Report4")
workbook.Worksheets.ActiveWorksheet = worksheet

' Access the pivot table by its name in the collection.
Dim pivotTable As PivotTable = worksheet.PivotTables("PivotTable1")
' Access the "Product" field.
Dim field As PivotField = pivotTable.Fields(1)
' Filter the "Product" field to display two products with the lowest sales.
Dim filter As PivotFilter = pivotTable.Filters.Add(field, pivotTable.DataFields(0), PivotFilterType.Count, 2)
filter.Top10Type = PivotFilterTop10Type.Bottom

The following code snippets (auto-collected from DevExpress Examples) contain references to the Top10Type property.

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