I'm creating a grid where each GroupByRow is indented to align with the header for the GroupByRow.Column. I did this by changing the GroupByRowUIElement.Rect my implementation of IUIElementCreationFilter.BeforeCreateChildElements :public bool BeforeCreateChildElements(UIElement parent){ if (parent is CellUIElement) { // Remove cells that fall under groupped columns UltraGridCell cell = parent.GetContext(typeof(UltraGridCell)) as UltraGridCell; if (!showCellValue(cell)) { RowUIElement rowUIElement = parent.GetAncestor(typeof(RowUIElement)) as RowUIElement; Rectangle rowRect = rowUIElement.Rect; if (rowRect.Left < parent.Rect.Right) rowUIElement.Rect = new Rectangle(parent.Rect.Right, rowRect.Top, rowRect.Width - parent.Rect.Right + rowRect.Left, rowRect.Height); parent.Parent.ChildElements.Remove(parent); parent.Dispose(); return true; } } else if (parent is GroupByRowUIElement) { UltraGridGroupByRow groupByRow = parent.GetContext(typeof(UltraGridGroupByRow)) as UltraGridGroupByRow; HeaderUIElement headerUIElement = groupByRow.Column.Header.GetUIElement(false) as HeaderUIElement; int newLeft; if (headerUIElement != null) newLeft = headerUIElement.Rect.Left; else newLeft = 1; parent.Rect = new Rectangle(newLeft, parent.Rect.Top, parent.Rect.Width - (parent.Rect.Left - newLeft), parent.Rect.Height); } else if (parent is GroupByRowDescriptionUIElement) { UltraGridGroupByRow groupByRow = parent.GetContext(typeof(UltraGridGroupByRow)) as UltraGridGroupByRow; HeaderUIElement headerUIElement = groupByRow.Column.Header.GetUIElement(false) as HeaderUIElement; int newLeft; if (headerUIElement != null) newLeft = headerUIElement.Rect.Left; else newLeft = 1; // Realign the description Rectangle descriptionRect = parent.Rect; Rectangle rowRect = parent.Parent.RectInsideBorders; parent.Rect = new Rectangle(newLeft, descriptionRect.Top, rowRect.Width, descriptionRect.Height); } return false;}Summaries are displayed in the GroupByRow positioned by their SourceColumn.I use the InitializeGroupByRow event to set the GroupByRow.Description to the value of the GroupByRow's group column.But grid still seems to think that the GroupByRow started all the way on the left instead of its indented position. So when the GroupByRow.Description is very short and there is a summary on the GroupByRow.Column, it figures that there's enough space between the left of the grid and GroupByRow.Column's summary to print the description and doesn't increase the height for the GroupByRow to draw the summary and the description on separate lines. Instead, I get overlapping text.Is there a way to get the grid to realize that I've repositioned the GroupByRowUIElement and GroupByRowDescriptionUIElement so it could correctly determine whether there would overlap between text elements? The Course 51842 "Advanced Development with NetAdvantage" manual mentions a PositionChildElements() method that's called between BeforeCreateChildElements and AfterCreateChildElements. But that doesn't seem to be exposed. I've also tried resizing/repositioning the GroupByRowDescriptionUIElement and SummaryFooterUIElement as part of the GroupByRowUIElement's block in BeforeCreateChildElements. But that resizing seems to be overridden at some point by the default sizing behavior.I hope I've adequately described my problem. Please let me know if I need to clarify any parts of it.Thanks.
Here're a couple of screenshots to help clarify the problem:Without a summary in the GroupByRow's column:With a summary. Notice that the summary and the group by row description are overlapped in the 3rd GroupByRow.
Hi,
I don't think this is going to work. The grid has no way to know that a UIElement was moved, so it's still going to assume it was in the same old position when it goes to position other elements. So a CreationFilter really isn't very useful for moving elements, unless you want to start moving all of the elements that may be related.