GridGroupingControl Custom Engine Issue
I am supressing any group caption for a group that only contains one row by using a custom engine. However when I use the custom engine it also suppresses the group summary for all groups (not just the groups containting only one row).
I am doing this in the isChildVisible event by returning false if the el type is a captionsection and the record count is 1. Why would this cause the summary to be suppressed and how can I make the summary follow the same rules as the header.
SIGN IN To post a reply.
4 Replies
AD
Administrator
Syncfusion Team
November 14, 2005 11:19 PM UTC
Just as a test, if you always return true in your isChildVisible event, does the summary show up then? If so, then you should see if you can spot some difference in the event args to distinguish the two cases so you can return true in the case where you want to see the child and false when you do not.
AD
Administrator
Syncfusion Team
November 15, 2005 04:38 PM UTC
Changing the event isChildVisible to always return true does still not display the summary row. Disabling the custome engine does show the summary row.
AD
Administrator
Syncfusion Team
November 15, 2005 05:47 PM UTC
In your IsChildVisible override, check for a GridSummarySection and return true to always see it.
public override bool IsChildVisible(Element el)
{
if (el is GridSummarySection)
{
return true;
}
else if (el is CaptionSection)
{
if (this.Details == null || this.Records.Count == 0 || this.Records.Count > 1)
return true;
else
return false;
}
else if (el is DetailsSection)
{
if (this.Details == null || this.Records.Count == 0 || this.Records.Count > 1)
return el.ParentGroup.IsExpanded;
else
return true;
}
else
return el.ParentGroup.IsExpanded;
}
AD
Administrator
Syncfusion Team
November 15, 2005 06:25 PM UTC
Turns out I had to add a section in the oninitialsections for the summary.
SIGN IN To post a reply.
- 4 Replies
- 1 Participant
-
AD Administrator
- Nov 14, 2005 11:02 PM UTC
- Nov 15, 2005 06:25 PM UTC