Back to Devexpress

PivotGridFieldBase.GetAvailableValues() Method

corelibraries-devexpress-dot-xtrapivotgrid-dot-pivotgridfieldbase-a1a807c9.md

latest3.4 KB
Original Source

PivotGridFieldBase.GetAvailableValues() Method

Returns a list of field values that are not excluded by filters applied to other fields and can be displayed.

Namespace : DevExpress.XtraPivotGrid

Assembly : DevExpress.PivotGrid.v25.2.Core.dll

NuGet Packages : DevExpress.PivotGrid.Core, DevExpress.Win.Navigation

Declaration

csharp
public object[] GetAvailableValues()
vb
Public Function GetAvailableValues As Object()

Returns

TypeDescription
Object[]

A list of field values that are not excluded by filters applied to other fields and can be displayed.

|

Remarks

Assume that a pivot grid contains two dimension fields: Category Name and Product Name.

If there is no filtering applied to the Category Name field, the GetAvailableValues method called for the Product Name field will return all unique field values, since all of them can be displayed.

If the Category Name field has a filter that allows displaying only the Beverages category, the GetAvailableValues method called for the Product Name field will return only products related to the Beverages category since all other products are excluded by the category filtering.

To obtain a list of available field values asynchronously, use the PivotGridFieldBase.GetAvailableValuesAsync method.

PivotGridControl also allows you to remove field values that cannot be displayed from filter drop-down lists. To do this, use the PivotGridOptionsFilterBase.ShowOnlyAvailableItems property for XtraPivotGrid , and the PivotGridWebOptionsFilter.ShowOnlyAvailableItems property for ASPxPivotGrid.

Note

If the PivotGridControl filters data by OLAP member unique names (controlled by the PivotGridFieldOptions.OLAPFilterByUniqueName and PivotGridOptionsOLAP.FilterByUniqueName options), the GetAvailableValues method returns them instead of field values.

See Also

ShowOnlyAvailableItems

GetAvailableValuesAsync()

PivotGridFieldBase Class

PivotGridFieldBase Members

DevExpress.XtraPivotGrid Namespace