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

Updating expression fields in GridGroupingControl

Thread ID:





49418 Sep 18,2006 08:53 PM UTC Sep 19,2006 11:04 PM UTC WinForms 2
Tags: Grouping
Michael Lorenz
Asked On September 18, 2006 08:53 PM UTC


I''m trying to do something fairly basic, but can''t find the documentation on how to do it.

I''m using a GridGroupingControl (bound to an underlying DataTable), and I''d like to have certain columns on a row update depending on values entered into another column. In the attached screenshot, I can modify the target %. The progress bar depends on a calculation involving that target % (so I''m using an ExpressionFieldDescriptor), and I''d like it to reflect the new values whenever the target % is changed.

In the account targets groupbox above the grid, I have three textboxes which show a sum of the values in the grid. These numbers should also change whenever a target % is modified in the grid.

What listeners or other method calls do I need to set up for this? And why don''t the epxression fields automatically pick up the changes in the grid?

If you have a working code example or can point me to where this is already explained, I''d appreciate it.



Administrator [Syncfusion]
Replied On September 19, 2006 10:05 AM UTC

Hi Michael,

The reason is that you are not setting the ProgressBar.ProgressValue property in a ProgressBar cell. The ExpressionFields does set the CellValue depending on values entered into required column in a Table (It doesn''t set the ProgressBar.Progress property). For changing the ProgressBar cell display value, you need to set the ProgressBar.ProgressValue property in the QueryCellStyleInfo. Below is a code snippet.

private void gridQueryCellStyleInfo(object sender, GridTableCellStyleInfoEventArgs e)
if( e.TableCellIdentity.Column != null && e.TableCellIdentity.Column.Name == "Expression" && e.Style.CellType == "ProgressBar")
if( e.Style.CellValue != null)
int progressValue = int.Parse(e.Style.CellValue.ToString());
e.Style.ProgressBar.ProgressValue = progressValue;

Sample : http://www.syncfusion.com/Support/user/uploads/ExpressionProgressBar_38d946a4.zip

Let me know if you are looking something different.

Best Regards,

Michael Lorenz
Replied On September 19, 2006 11:04 PM UTC

Hi Haneef,

That was pretty much it, yeah. Your clarification also helped me get rid of another weird behaviour, where only alternate rows were getting updated properly. ;-)

Thanks a lot,


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

or the page will be automatically redirected to 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