DxSummaryItemBase<TModel>.GroupSummaryPosition Property

Specifies the group summary item's position.

Namespace: DevExpress.Blazor

Assembly: DevExpress.Blazor.v20.2.dll

Declaration

[Parameter]
[DefaultValue(GroupSummaryPosition.GroupRow)]
public GroupSummaryPosition GroupSummaryPosition { get; set; }

Property Value

Type Default Description
GroupSummaryPosition

GroupRow

A GroupSummaryPosition enumeration value.

Remarks

To calculate group summaries in the Data Grid, add DxDataGridSummaryItem objects to the GroupSummary collection. Use the GroupSummaryPosition property to position group summaries. The following values are available:

NOTE

This property is not in effect if the summary item is added to the TotalSummary collection.

<DxDataGrid Data="@SalesData"
            ShowGroupPanel="true">
    <Columns>
        <DxDataGridSpinEditColumn Field=@nameof(SaleInfo.OrderId)
                                  Width="120px" />
        <DxDataGridColumn Field=@nameof(SaleInfo.Region)
                          GroupIndex="0"
                          Width="240px" />
        <DxDataGridColumn Field=@nameof(SaleInfo.Country)
                          GroupIndex="1" />
        <DxDataGridDateEditColumn Field="@nameof(SaleInfo.Date)"
                                  DisplayFormat="D" />
        <DxDataGridColumn Field=@nameof(SaleInfo.City)/>
        <DxDataGridSpinEditColumn Field="@nameof(SaleInfo.Amount)"
                                  DisplayFormat="c"
                                  Width="120px" />
    </Columns>
    <GroupSummary>
        <DxDataGridSummaryItem SummaryType=SummaryItemType.Count
                               GroupSummaryPosition="GroupSummaryPosition.GroupRow" />
        <DxDataGridSummaryItem Field=@nameof(SaleInfo.Amount)
                               SummaryType=SummaryItemType.Sum
                               GroupSummaryPosition="GroupSummaryPosition.GroupFooter"
                               DisplayFormat="Total: {0:c}" />
        <DxDataGridSummaryItem Field=@nameof(SaleInfo.Date)
                               SummaryType=SummaryItemType.Min
                               DisplayFormat="First: {0:D}"
                               GroupSummaryPosition="GroupSummaryPosition.GroupFooter" />
    </GroupSummary>
</DxDataGrid>

Data Grid Group Summary Position

Run Demo: Data Grid - Group Summary

See Also