.NET Framework 4.5.2+
.NET Framework 4.5.2+
.NET Standard 2.0+
.NET Core 3.0+
Row

PivotFieldCollection Interface

Represents the collection of all fields in a PivotTable report.

Namespace: DevExpress.Spreadsheet

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

Declaration

public interface PivotFieldCollection :
    ISimpleCollection<PivotField>,
    IEnumerable<PivotField>,
    IEnumerable,
    ICollection
Public Interface PivotFieldCollection
    Inherits ISimpleCollection(Of PivotField),
             IEnumerable(Of PivotField),
             IEnumerable,
             ICollection
public interface PivotFieldCollection :
    ISimpleCollection<PivotField>,
    IEnumerable<PivotField>,
    IEnumerable,
    ICollection
Public Interface PivotFieldCollection
    Inherits ISimpleCollection(Of PivotField),
             IEnumerable(Of PivotField),
             IEnumerable,
             ICollection
public interface PivotFieldCollection :
    ISimpleCollection<PivotField>,
    IEnumerable<PivotField>,
    IEnumerable,
    ICollection
Public Interface PivotFieldCollection
    Inherits ISimpleCollection(Of PivotField),
             IEnumerable(Of PivotField),
             IEnumerable,
             ICollection

Remarks

When you create a pivot table, the PivotFieldCollection collection is populated automatically based on information in the source data (or more precisely PivotCache). For example, if you use a cell range as a data source for your PivotTable report, each column in the source range will be treated as a separate field, and the column label will be used as the value of the PivotField.Name property.

Besides fields that originate from the source data, the PivotFieldCollection collection may also contain calculated fields and fields that appear as a result of grouping.

To return a collection of all fields in a specific PivotTable report, use the PivotTable.Fields property. An individual PivotTable field is represented by the PivotField object, which can be accessed by its name or index in the collection using the PivotFieldCollection.Item property.

If you need to return a subset of fields located in a specific area of a PivotTable report, use the following properties of the PivotTable object.

See Also