Back to Devexpress

WindowExpressionBinding Class

wpf-devexpress-dot-xpf-dot-pivotgrid-db69e7b4.md

latest3.2 KB
Original Source

WindowExpressionBinding Class

Specifies a custom string expression with window functions to calculate values. Used as a PivotGrid’s field calculation databinding in Optimized mode.

Namespace : DevExpress.Xpf.PivotGrid

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

NuGet Package : DevExpress.Wpf.PivotGrid

Declaration

csharp
public class WindowExpressionBinding :
    DirectedCalculationBinding,
    IExpressionBinding
vb
Public Class WindowExpressionBinding
    Inherits DirectedCalculationBinding
    Implements IExpressionBinding

Remarks

The following example shows how to set up WindowExpressionBinding:

xaml
<dxpg:PivotGridControl.Fields>
    <dxpg:PivotGridField
        Area="DataArea"
        AreaIndex="2"
        Caption="Total"
        Name="fieldWindowExpression">
        <dxpg:PivotGridField.DataBinding>
            <dxpg:WindowExpressionBinding
                    Expression="Total(Sum([Extended Price]))" PartitioningCriteria="ColumnValueAndRowParentValue"
                <dxpg:WindowExpressionBinding.Source>
                    <dxpg:DataSourceColumnBinding ColumnName="Extended Price" />
                </dxpg:WindowExpressionBinding.Source>
            </dxpg:WindowExpressionBinding>
        </dxpg:PivotGridField.DataBinding>
    </dxpg:PivotGridField>
</dxpg:PivotGridControl.Fields>

See the following example for more Data Binding usage examples:

View Example: Pivot Grid for WPF - Bind Pivot Grid Fields to Window Calculations

For more information, review the following topic: Optimized Mode and Data Binding API.

Inheritance

Object DispatcherObject DependencyObject ContentElement FrameworkContentElement DXFrameworkContentElement DataBinding CalculationBinding DirectedCalculationBinding WindowExpressionBinding

See Also

WindowExpressionBinding Members

Bind Pivot Grid Fields to Window Calculations

DevExpress.Xpf.PivotGrid Namespace