Articles in this section

How to display summary information in group caption row in WinForms GridGroupingControl?

Summaries


In WinForms GridGroupingControl, you can display the summary information in the Group Caption using the TopLevelGroupOptions.CaptionText Property.

 

For example, in the below code snippet, the summary text is added into the group caption with the help of TopLevelGroupOptions.CaptionText property.

 

C#

GridSummaryColumnDescriptor scd = new GridSummaryColumnDescriptor("Summarycolumn1", SummaryType.Count, "CategoryName", "{Count} Records");
GridSummaryRowDescriptor srd = new GridSummaryRowDescriptor("Summaryrow1", "Summary Total", scd);
this.gridGroupingControl1.TableDescriptor.SummaryRows.Add(srd);
this.gridGroupingControl1.TopLevelGroupOptions.CaptionText = "EventList - {RecordCount} Event(s)-{Summarycolumn1} mins";

VB

Dim scd As New GridSummaryColumnDescriptor("Summarycolumn1", SummaryType.Count, "CategoryName", "{Count} Records")
Dim srd As New GridSummaryRowDescriptor("Summaryrow1", "Summary Total", scd)
Me.gridGroupingControl1.TableDescriptor.SummaryRows.Add(srd)
Me.gridGroupingControl1.TopLevelGroupOptions.CaptionText = "EventList - {RecordCount} Event(s)-{Summarycolumn1} mins"

Samples:

C#: SummaryInformation_CS

VB: SummaryInformation_VB


Reference Link:
 
Summaries 

Did you find this information helpful?
Yes
No
Help us improve this page
Please provide feedback or comments
Comments (0)
Access denied
Access denied