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.
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

GGC : Grouping columns

Thread ID:

Created:

Updated:

Platform:

Replies:

39355 Jan 5,2006 06:24 AM UTC Jan 12,2006 01:16 PM UTC Windows Forms 6
loading
Tags: Grouping
Anupama
Asked On January 5, 2006 06:24 AM UTC

I have a grid in which 2 of the columns are CategoryID and CategoryDesc. I want categorize based on categoryid but in the CaptionText I want to show the CategoryDesc. How can I do that? None of the captiontext tokens allow you to select text from another column.

stanleyj [Syncfusion]
Replied On January 5, 2006 10:48 AM UTC

Hi Anupama, The text in caption cell can be changed handling the QueryCellStyleInfo handler. private void gridGroupingControl1_QueryCellStyleInfo(object sender, GridTableCellStyleInfoEventArgs e) { if(e.TableCellIdentity.TableCellType == GridTableCellType.GroupCaptionCell) e.Style.Text = "My Text"; } Best regards, Stanley

Anupama
Replied On January 10, 2006 06:49 AM UTC

Thanks Stanley! That worked.

Anupama
Replied On January 12, 2006 05:34 AM UTC

How can I get the tokens to display programatically in the Caption Text? Specifically the {RecordCount} token. The documentation says this comes from the CaptionSection.ParentGroup.GetFilteredRecordCount() but CaptionSection is a member of which class in e.TableCellIdentity? (I need to write this piece of code in QueryCellStyleInfo event handler). >Hi Anupama, > >The text in caption cell can be changed handling the QueryCellStyleInfo handler. > > private void gridGroupingControl1_QueryCellStyleInfo(object sender, GridTableCellStyleInfoEventArgs e) > { > if(e.TableCellIdentity.TableCellType == GridTableCellType.GroupCaptionCell) > e.Style.Text = "My Text"; > } > >Best regards, >Stanley

stanleyj [Syncfusion]
Replied On January 12, 2006 12:58 PM UTC

Hi Anupama, Let me know if this will work for you. e.TableCellIdentity.DisplayElement.ParentGroup.GetFilteredRecordCount() Best regards, Stanley

stanleyj [Syncfusion]
Replied On January 12, 2006 12:58 PM UTC

Hi Anupama, Let me know if this will work for you. e.TableCellIdentity.DisplayElement.ParentGroup.GetFilteredRecordCount() Best regards, Stanley

Anupama
Replied On January 12, 2006 01:16 PM UTC

Yes! This works exactly the way its supposed to. Thanks! >Hi Anupama, > > >Let me know if this will work for you. > >e.TableCellIdentity.DisplayElement.ParentGroup.GetFilteredRecordCount() > >Best regards, >Stanley

CONFIRMATION

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.

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

;