Back to Devexpress

CustomSummaryEventArgs Class

corelibraries-devexpress-dot-data-0e0886cd.md

latest3.8 KB
Original Source

CustomSummaryEventArgs Class

Provides data for the GridView.CustomSummaryCalculate event.

Namespace : DevExpress.Data

Assembly : DevExpress.Data.v25.2.dll

NuGet Package : DevExpress.Data

Declaration

csharp
public class CustomSummaryEventArgs :
    EventArgs
vb
Public Class CustomSummaryEventArgs
    Inherits EventArgs

CustomSummaryEventArgs is the data class for the following events:

LibraryRelated API Members
WinForms ControlsGridView.CustomSummaryCalculate
WPF ControlsGridControl.CustomSummary
ASP.NET Web Forms ControlsASPxGridBase.CustomSummaryCalculate

Remarks

The GridView.CustomSummaryCalculate event enables you to calculate summary values manually. This event is raised for each data row involved in the calculations, it also fires before and after calculations allowing you to perform any initialization and finalization required. The CustomSummaryEventArgs class introduces the CustomSummaryEventArgs.SummaryProcess property that identifies whether initialization, finalization or total summary value calculation should be performed.

When calculating, read the CustomSummaryEventArgs.FieldValue property value to obtain the currently processed field value. If you need the values of other fields, use the CustomSummaryEventArgs.RowHandle property. It enables you to identify the current row and, thus, obtain its values. The total summary value should be accumulated in the CustomSummaryEventArgs.TotalValue property.

If calculating a group summary value, you may need the CustomSummaryEventArgs.GroupLevel and CustomSummaryEventArgs.GroupRowHandle properties to identify the currently processed group. You can determine whether a group summary will be calculated using the CustomSummaryEventArgs.IsGroupSummary property value.

Note : use the CustomSummaryEventArgs.Item property to access the summary item that provides the settings for the summary calculation.

CustomSummaryEventArgs objects are automatically created and passed to GridView.CustomSummaryCalculate event handlers.

Inheritance

Object EventArgs CustomSummaryEventArgs

See Also

CustomSummaryEventArgs Members

Working with Total, Group, and Custom Summaries in Code

DevExpress.Data Namespace