Total Summary Computation

Our Blazor Data Grid can compute summaries (using aggregate functions such as Sum, Min, Max, etc) for both the entire contents of the grid and at each individual group level. “Total” summaries are calculated across all grid records and displayed within the grid’s footer. To create total summaries, add DxDataGridSummaryItem objects to the TotalSummary collection.

Key DxDataGridSummaryItem properties are summarized below.

  • SummaryType – Specifies the aggregate function (Sum, Min, Max, Avg, and Count) used.
  • Field – Specifies the name of the data field whose values are used to calculate the summary. The Min and Max functions require a numeric or date-time data field. The Avg and Sum functions work with numeric fields only. For the Count function, you do not need to set this property.
  • ShowInColumn – Specifies the name of the column used to display the summary.
  • DisplayFormat – Specifies summary display format. The ‘{0}’ placeholder returns the summary value and ‘{1}’ returns the parent column’s caption. If you do not specify this property, the following format is applied: ‘{Summary function}: {summary value}’.
3/5/2021 Palau Alice Mutton $8.00
2/28/2021 Sri Lanka Aniseed Syrup $11.00
2/19/2021 Iraq Boston Crab Meat $1.00
2/27/2021 Dominica Camembert Pierrot $8.00
2/23/2021 Uruguay Carnarvon Tigers $8.00
3/2/2021 Nigeria Chai $3.00
2/24/2021 Ethiopia Chang $2.00
2/20/2021 Republic of Korea Chartreuse verte $3.00
2/22/2021 Saint Pierre and Miquelon Chef Anton's Cajun Seasoning $8.00
2/19/2021 Pakistan Chef Anton's Gumbo Mix $8.00
First: Friday, February 19, 2021
Count: 75
Sum: $462.00

Group Summary Computations

Group summaries (using aggregate functions such as Sum, Min, Max, Avg, and Count) are calculated across all rows within a group and displayed in the group row or group footer. To create group summaries, add DxDataGridSummaryItem objects to the GroupSummary collection.

Use the GroupSummaryPosition property to position group summaries. The following values are available:

Region: Africa (Count: 15)
Region: Asia (Count: 20)
Region: Australia (Count: 10)
Region: Europe (Count: 17)
Region: North America (Count: 29)
Region: South America (Count: 16)