We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Summary Column Descriptor

I am trying to create a grouping grid in which a summary column is a calculation of another two summary columns. An example to clarify: summary column 'A' gets the sum of -- say the number of apples in a farm. Summary column 'B' obtains the total number of fruits. Summary column 'C' should show the percentage of apples with respect to the number of fruits.

Thus far, I'm only able to make standard calculations (average, sum, count etc.) based on the constituents, but not based on the other summary columns.

I'd greatly appreciate if someone could point me to the documentation for this or post a solution for this problem. Thanks.

8 Replies

HA haneefm Syncfusion Team June 21, 2007 03:12 PM UTC

Hi Tony,

Please refer to the samples named under Summaries category, that has been shipped along with the product. Below are the some of the samples.

SummaryTutorial (\Syncfusion\EssentialStudio\5.1.0.51\Windows\Grid.Grouping.Windows\Samples\2.0\Summaries\SummaryTutorial \cs )
- This sample demonstrates the creation of summaries through the designer.
SummariesForNestedTablesAndGroups (\Syncfusion\EssentialStudio\5.1.0.51\Windows\Grid.Grouping.Windows\Samples\2.0\Summaries\SummariesForNestedTablesAndGroups\cs )
- This sample demonstrates the adding of Summaries through code.
CustomSummaries (\Syncfusion\EssentialStudio\5.1.0.51\Windows\Grid.Grouping.Windows\Samples\2.0\Summaries\CustomSummary\cs )
- This sample demonstrates the implementation of the CustomSummaries and the CustomCounters.
SummaryInCaption (\Syncfusion\EssentialStudio\5.1.0.51\Windows\Grid.Grouping.Windows\Samples\2.0\Summaries\SummaryInCaption\cs )
- This sample demonstrates the showing of a summary in the caption cells.
SortBySummaryInCaption (\Syncfusion\EssentialStudio\5.1.0.51\Windows\Grid.Grouping.Windows\Samples\2.0\Summaries\SortBySummaryInCaption\cs )
- This samples demonstrates how to sort groups by the value of a summary.
WeightedSummary (\Syncfusion\EssentialStudio\5.1.0.51\Windows\Grid.Grouping.Windows\Samples\2.0\Summaries\WeightedSummary\cs )
- This sample creates a CustomSummary that does a weighted average calculation

Best regards,
Haneef


TD Tony De Ycaza June 25, 2007 04:38 PM UTC

Hi Haneef,

I currently have version 4.2.0.37, so I don't have most of the examples that you have listed.
However, I was able to view the CustomSummary sample but the calculations were performed on the rows themselves and not on the collapsed data (data in a row after grouping). Could you provide a small demo?

regards,

- Tony

>Hi Tony,

Please refer to the samples named under Summaries category, that has been shipped along with the product. Below are the some of the samples.

SummaryTutorial (\Syncfusion\EssentialStudio\5.1.0.51\Windows\Grid.Grouping.Windows\Samples\2.0\Summaries\SummaryTutorial \cs )
- This sample demonstrates the creation of summaries through the designer.
SummariesForNestedTablesAndGroups (\Syncfusion\EssentialStudio\5.1.0.51\Windows\Grid.Grouping.Windows\Samples\2.0\Summaries\SummariesForNestedTablesAndGroups\cs )
- This sample demonstrates the adding of Summaries through code.
CustomSummaries (\Syncfusion\EssentialStudio\5.1.0.51\Windows\Grid.Grouping.Windows\Samples\2.0\Summaries\CustomSummary\cs )
- This sample demonstrates the implementation of the CustomSummaries and the CustomCounters.
SummaryInCaption (\Syncfusion\EssentialStudio\5.1.0.51\Windows\Grid.Grouping.Windows\Samples\2.0\Summaries\SummaryInCaption\cs )
- This sample demonstrates the showing of a summary in the caption cells.
SortBySummaryInCaption (\Syncfusion\EssentialStudio\5.1.0.51\Windows\Grid.Grouping.Windows\Samples\2.0\Summaries\SortBySummaryInCaption\cs )
- This samples demonstrates how to sort groups by the value of a summary.
WeightedSummary (\Syncfusion\EssentialStudio\5.1.0.51\Windows\Grid.Grouping.Windows\Samples\2.0\Summaries\WeightedSummary\cs )
- This sample creates a CustomSummary that does a weighted average calculation

Best regards,
Haneef


HA haneefm Syncfusion Team June 25, 2007 10:51 PM UTC

Hi Tony,

Here is a minimal sample that shows you "How to add a summary descriptor to the groups in a grid?". Please try the sample and let me know if this helps.
GGCGroupSummaryDescriptor.zip

See the below forum thread for multiple SummaryRow at the very top of grid.
http://www.syncfusion.com/support/forums/message.aspx?MessageID=48942

Best regards,
Haneef


TD Tony De Ycaza June 27, 2007 12:13 AM UTC

Hi Haneef,

I checked the examples but they don't quite have the information I was looking for.
The attached picture illustrates the problem a litle bit better. The grid has been grouped by two columns. The summary columns are in beige and display the totals of the rows.
I need to find a way to display DIFF/ACTUAL of the totals (circled in blue and green) in the last column (DIFF %, circled in red).

Thanks in advance,

- Tony


example28.zip


SP Sai Pavan Kumar September 3, 2010 06:56 AM UTC

Hi

In the attached image, i need to add rows in the first column ( Column header - 'Sales')

please help me to do this..

awaiting for your reply at the earliest..


thanks and regards
pavan



doubt_a6aefb19.zip


JJ Jisha Joy Syncfusion Team September 6, 2010 09:56 AM UTC

Hi Pavan,

Please refer the following code to insert row to the top in GridConrol.

gridControl1.Rows.InsertRange(0, 1);

Regards,
Jisha



SP Sai Pavan Kumar September 7, 2010 06:47 AM UTC

Hi Jisha

Thanks for your reply..
i was asking the same for GridgroupingControl and not for Gridcontrol.

Please answer my other question "How to fomat a cell in a Grid grouping control... also how to format an entire row in GRID GROUPING CONTROL"

Thanks
Pavan



JJ Jisha Joy Syncfusion Team September 8, 2010 10:10 AM UTC

Hi Pavan,

Please try using the Insert method in the record collections. The UnSortedRecords represents the original records in same order as like underlying datasource.

this.gridGroupingControl1.Table.UnsortedRecords.Insert(4,record);

You could use the QueryCellStyleInfo event to set syles to ceels or rows in GridGroupingControl

void gridGroupingControl1_QueryCellStyleInfo(object sender, GridTableCellStyleInfoEventArgs e)
{

if (e.TableCellIdentity.RowIndex == 4 && e.TableCellIdentity.ColIndex == 2)
e.Style.Font.Bold = true;
}


-Jisha


Loader.
Live Chat Icon For mobile
Up arrow icon