Skip to main content
Tag

PivotGridField.DataBinding Property

Gets or sets an object that specifies the Pivot Grid field’s source data.

Namespace: DevExpress.Xpf.PivotGrid

Assembly: DevExpress.Xpf.PivotGrid.v24.1.dll

NuGet Package: DevExpress.Wpf.PivotGrid

Declaration

public DataBinding DataBinding { get; set; }

Property Value

Type Description
DataBinding

A DataBinding object that specifies the source data for the Pivot Grid fields.

Remarks

Pivot Grid uses the Binding API to bind Pivot Grid fields to data. Data binding sources can be columns in a data source, calculated expressions, or window calculations.

Refer to the following topics for information on how to bind Pivot Grid fields to data:

Each specified binding object is a DataBinding descendant. This object is assigned to the Pivot Grid field’s DataBinding property.

The following code snippet illustrates the Pivot Grid’s Product Sales field bound to the Extended Price source column:

<dxpg:PivotGridControl>
    <dxpg:PivotGridControl.Fields>
      <dxpg:PivotGridField
          Area="DataArea"
          AreaIndex="5"
          Caption="Product Sales"
          CellFormat="C"
          Name="fieldSales">
          <dxpg:PivotGridField.DataBinding>
              <dxpg:DataSourceColumnBinding ColumnName="Extended Price" />
          </dxpg:PivotGridField.DataBinding>
        </dxpg:PivotGridField>
      </dxpg:PivotGridControl.Fields>
</dxpg:PivotGridControl>

The following code snippets (auto-collected from DevExpress Examples) contain references to the DataBinding 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