Hi,
I'm using UltraConrolContainerEditor.
I want to assign values of child band to nested grid, so each row will display related child band in the cell row.
I added unbound column to parent grid and set the data type of the column to IList.
I've tried to assign the values of the child band to the cell.
However I'm having problem with picking those values by nested grids. (have two grids for rendering and editing control)
Can I get some example on that?
Thanks,
s
I display 8 cells in the parent grid and 3 cells in the child grids.
I have more cells in child grids but i'm hiding them, I've loaded them all once and it loaded fine as well.
The performance is fine for now, it does not freeze or anything like that. (know more about that as I go on with testing)
Thank you again,
Great. Just out of curiosity, how many cells are visible at once in the main grid and how many cells in the child grid in the cell?
And how's the performance?
Hello,
Thank you so much it is working now and doing what I was looking for!
Your guidance Mike helped me to understand better UltraControlContainerEditor, UltraGrid and of course to solve mine problem.
So just quick summary what I have:
In 'ParentGrid_InitializeLayout':
Me.UltraControlContainerEditor1.RenderingControl = Me.Grid1Me.UltraControlContainerEditor1.EditingControl = Me.Grid2
UltraControlContainerEditor1.RenderingControlPropertyName = "DataSource" UltraControlContainerEditor1.EditingControlPropertyName = "DataSource"
Me.ParentGrid.DisplayLayout.Bands(0).Columns("UnboundColumn").EditorComponent = Me.UltraControlContainerEditor1
In ParentGrid_InitializeRow:
e.Row.Cells("UnboundCell").Value = MyDataTable
And works like a charm!
Thank you,
Well, one obvious missing piece here is the EditingControlPropertyName / RenderingControlPropertyName. By default, the ControlContainerEditor will try to link up the cell's Value with the Value property of the EditingControl (which the WinGrid does not have). Then it looks for Text, so it's probably setting the Text property of your grid to a DataSet - or trying and failing to do so.
You need to set these to "DataSource", since that's what you want to set on the child grid.
What I do is in 'ParentGrid_InitializeLayout' I set:
Me.UltraControlContainerEditor1.RenderingControl = Me.Grid1 Me.UltraControlContainerEditor1.EditingControl = Me.Grid2 Me.ParentGrid.DisplayLayout.Bands(0).Columns("UnboundColumn").EditorComponent = Me.UltraControlContainerEditor1
and then in ParentGrid_InitializeRow:
but the cell remains blank.
What am I missing?