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 : Nov 16th 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Finding columns associated with CaptionSummaryRows

Thread ID:

Created:

Updated:

Platform:

Replies:

20811 Oct 26,2004 11:08 AM UTC Oct 27,2004 06:34 AM UTC WinForms 2
loading
Tags: Grouping
Anthony Avella
Asked On October 26, 2004 11:08 AM UTC

I''m trying to hide the value in the cells of various detail records when that column is a column which is part of a CaptionSummaryRow. I''ve been using the following test in my QueryCellStyleInfo event handler: if ((e.TableCellIdentity.TableCellType == GridTableCellType.RecordFieldCell || e.TableCellIdentity.TableCellType == GridTableCellType.AlternateRecordFieldCell) && e.TableCellIdentity.SummaryColumn != null) I thought that the e.TableCellIdentity.SummaryColumn property told me whether a column was associated with any CaptionSummaryRow in a grid. Can you please tell me how to properly find this out in the event handler?

Administrator [Syncfusion]
Replied On October 27, 2004 06:21 AM UTC

e.TableCellIdentity.SummaryColumn is only set if th eelement is a captionrow or summaryrow. So, if you want this information on recordrows, then you would have to track it yourself. You could add a private ArrayList member, and add the column names used in your summaries to the ArrayList as you add the columns to teh summaryrow. Then in QueryCellStyleInfo, you could use code like this where colsInSummary is the arraylist:
//blanks out the summary column
if ((e.TableCellIdentity.TableCellType == GridTableCellType.RecordFieldCell 
|| e.TableCellIdentity.TableCellType == GridTableCellType.AlternateRecordFieldCell)
&& this.colsInSummary.IndexOf(e.TableCellIdentity.SummaryColumn.Column.Name) > -1)
{
	e.Style.CellValue = "";
}

Administrator [Syncfusion]
Replied On October 27, 2004 06:34 AM UTC

If you want to catch the cell in the summary itself (as opposed to the record cells contributing to the summary), then you can use code like if ((e.TableCellIdentity.TableCellType == GridTableCellType.GroupCaptionSummaryCell && e.TableCellIdentity.SummaryColumn != null) since e.TableCellIdentity.SummaryColumn should be set for these cell types.

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

;