aspnet-119612-components-card-view-concepts-data-shaping-and-manipulation-data-summaries-predefined-aggregate-functions.md
When you create a summary item (an ASPxCardViewSummaryItem instance), you can use the ASPxSummaryItemBase.SummaryType property to define its aggregate function type. ASPxCardView provides a built-in implementation of the most popular aggregate functions such as Average, Count, Max, Min, and Sum. The summaries of these predefined types are implemented so that they have a specific structure, and they can be localized and formatted with ease.
The display text of a calculated summary consists of the summary label (which describes the applied aggregate function) and the summary display value (which is the calculated value with applied formatting, if any).
The table below describes the predefined function types, and lists the corresponding resource strings (and their default format patterns) used for localization.
| Summary Type | Description | Display in Column | Resource String ID | Default Format |
|---|---|---|---|---|
| Average | Calculates a column’s average value. | Calculated ( FieldName ) | ASPxCardViewStringId.Summary_Average | Avg={0} |
| Max | Calculates a column’s maximum value. | Calculated ( FieldName ) | ASPxCardViewStringId.Summary_Max | Max={0} |
| Min | Calculates a column’s minimum value. | Calculated ( FieldName ) | ASPxCardViewStringId.Summary_Min | Min={0} |
| Sum | Calculates the sum of a column’s values. | Calculated ( FieldName ) | ASPxCardViewStringId.Summary_Sum | Sum={0} |
| Count | Calculates the number of records in a column. | Any | ASPxCardViewStringId.Summary_Count | Count={0} |
The {0} placeholder in format patterns contains the calculated summary value.
Note that the resource strings listed in this table are used to localize summary label text, but not summary display values. You can utilize these resource strings when you localize your application through global resources, as described in the following help topic: Localizing ASP.NET Controls via Global Resources (Obsolete from 11.2).
ASPxCardView allows you to customize summary display text. You can use the following properties to provide a custom format for the summary value, or even the entire summary text displayed by a summary item:
A column’s DisplayFormatString
A summary item’s ValueDisplayFormat
A summary item’s DisplayFormat
Note that you can also use the ASPxCardView.SummaryDisplayText event to provide custom display text for summaries.