Skip to main content

DxGrid.GetTotalSummaryFormattedValue(IGridSummaryItem) Method

Gets a total summary item’s formatted value.

Namespace: DevExpress.Blazor

Assembly: DevExpress.Blazor.v24.1.dll

NuGet Package: DevExpress.Blazor


public string GetTotalSummaryFormattedValue(
    IGridSummaryItem item


Name Type Description
item IGridSummaryItem

The total summary item.


Type Description

The total summary item’s formatted value.


Use the ValueDisplayFormat property to specify the pattern to format the summary value.

The following code snippet customizes the Unit Price column’s footer. The footer contains the summary’s label and formatted value.

@using Microsoft.EntityFrameworkCore
@inject IDbContextFactory<NorthwindContext> NorthwindContextFactory
@implements IDisposable
@* ... *@
<DxGrid @ref="Grid3"
        <DxGridDataColumn FieldName="Country" />
        <DxGridDataColumn FieldName="City" />
        <DxGridDataColumn FieldName="OrderDate" />
        <DxGridDataColumn FieldName="UnitPrice" DisplayFormat="c" Width="180px">
                    var summaryItems = context.SummaryItems;
                    if (summaryItems.Any())
                        foreach (var i in summaryItems)
                            <text> of </text>
                            <text>: </text>
        <DxGridDataColumn FieldName="Quantity" />
        <DxGridSummaryItem SummaryType="GridSummaryItemType.Max" ValueDisplayFormat="c" FieldName="UnitPrice" />
@* ... *@
@code {
    object Data { get; set; }
    NorthwindContext Northwind { get; set; }
    @* ... *@
    IGrid Grid3 { get; set; }

    protected override void OnInitialized() {
        Northwind = NorthwindContextFactory.CreateDbContext();
        Data = Northwind.Invoices
    @* ... *@
    public void Dispose() {

DevExpress Blazor Grid - Total Summary

For more information about summaries in the Grid component, refer to the following topic: Summary in Blazor Grid.

See Also