GridSummaryRow - show category in summary column?

Is there a way to display the {category} in a summary column? For example if I group by account# I want to display the account# in the Account column instead of in the caption.

1 Reply

AD Administrator Syncfusion Team October 16, 2006 04:41 AM UTC

Hi Michael,

You could try handling QueryCellStyleInfo event as shown in the following code:

switch(e.TableCellIdentity.TableCellType )
{
case GridTableCellType.SummaryTitleCell:
GridSummaryRow row = e.TableCellIdentity.DisplayElement as GridSummaryRow;
if( row != null && row.ParentGroup != null)
{
object category = row.ParentGroup.Category;
if( category != null && category != string.Empty )
e.Style.Text = category.ToString() ;
}
break;
}

Please let me know if you need further assistance.

Regards,
Haneef

Loader.
Up arrow icon