Hello,
I have 31 columns grid and I have to initialize some control in customized header cells. And I have 2 questions:
1. Which event I should use to have header cell != null by the moment of initialization?
2. I have this code:
HeaderCellControl hcc = (HeaderCellControl)((RowsManager)row.Manager).HeaderRow.Cells[FieldName].Control;
When InitializeRow event fires, e.Row.Cells contains all 31 cells but, for cells which index >= 8, HeaderCellControl is always null! Why?
Thank you
Found 1 more issue. In some cases I set Visibility property of my custom control to Collapse, but when I resize a column, control changes its state to Visible. Why?
I have customized HeaderCell style and put a custom UserControl there. When grid layout has been built, I need to send some data to that control, depending on value type in each column. Depending on those data I change control visual style and some contents. That's why I have to find this control in DataTemplate and set up some its properties.
Hi,
The grid uses Virtualization and recycling, so only cells that are currently visible actually have controls attached to them, and the controls that were previously used are then reused for the new visible cells, this keeps our memory footprint low, and the silverlight application fast.
What kind of initialization are you trying to do, perhaps i can help you find another way to initialize.
-SteveZ