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. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Summary Text from GridEngine

Thread ID:





65252 Jul 25,2007 04:27 PM UTC Jul 27,2007 02:14 AM UTC WinForms 3
Tags: GridControl
Asked On July 25, 2007 04:27 PM UTC


I am trying to read the Summarytext of the summary column for a specific group using
I am able to get the SummaryText value but when user change the cell value and summary get recalculated then also i am getting old value by gridEngine.
In Grid summary cell i can see the new value which is set in querycellstyleinfo event.
I have to close and reopen the window to get the new value in GridEngine summaryText.
Please can you show me some pointer to get the latest value in gridEngine.

haneefm [Syncfusion]
Replied On July 25, 2007 07:50 PM UTC

Hi Harshad,

By default, the summaries should be refreshed as you leave the row (not the cell). If you want the summaries updated as you leave the cell , you can add a CurrentRecordContextChange event handler, and trigger the actions there.

private void grid1_CurrentRecordContextChange(object sender, CurrentRecordContextChangeEventArgs e)
if(e.Action == CurrentRecordAction.CurrentFieldChanged
|| e.Action == CurrentRecordAction.EndEditComplete )
this.gridGroupingControl1.Table.SummaryDirty = true;
this.gridGroupingControl1.Table.TableDirty = true;

To update the summaries as you change the underlying datasource, Please refer to the below form thread.

Best Regards,

Replied On July 26, 2007 09:12 AM UTC

Thanks For reply,
Actually my problem is in the grid sumamry gets updated. but since these are the calculated column and value is calculated in queryCellStyleinfo. record value is not get updated in the underline datasource for these calculated columns and therfore summary value in gridEngine is not get updated even though i move from the row.
Please can you tell me how to refesh gridEngine ? is there any method or property to refresh this?

Saravanan A [Syncfusion]
Replied On July 27, 2007 02:14 AM UTC

Hi Harshad,

If you are setting the summary value through QueryCellStyleInfo event, it will not get stored internally with the summary elements. So GridEngine.GetSummaryText and GetDisplayText methods will not return those values. In this case you can try getting the RowIndex and ColIndex of the summary cell and access the CellValue through the indexers of gridGroupingControl1.TableModel. This will trigger the QuerryCellStyleInfo event for that cell and then return the value.
Here is the code snippet.

int rowIndex = gridGroupingControl1.Table.NestedDisplayElements.IndexOf(summaryRow);
GridTableDescriptor tableDescriptor = null;
foreach (GridSummaryColumnDescriptor scd in summaryRow.SummaryRowDescriptor.SummaryColumns)
tableDescriptor = scd.TableDescriptor;
int fieldIndex = tableDescriptor.NameToField(scd.DataMember);
int colIndex = scd.TableDescriptor.FieldToColIndex(fieldIndex);

Console.WriteLine(gridGroupingControl1.TableModel[rowIndex, colIndex].CellValue);

Best Regards,


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon