The UltraDataSource is created by code as below. The datasource then is assigned to a UltraGrid. But the grid only display the rows in Band 0, the rows in child band can't be viewed in the application. Can someone help with this?
Thank you!!!
//Define the datasourceInfragistics.Win.UltraWinDataSource.UltraDataSource ds = new UltraDataSource();
for (int i = 0; i < columnNames.Length; i++){ string type = columnTypes[i]; ds.Band.Columns.Add(columnNames[i], Type.GetType(type));}ds.Band.ChildBands.Add("ChildBand");
//populate dataobject[ row1 = new object[ {"1", "2", "3"};UltraDataRow row11 = ds.Rows.Add(row1);row11.GetChildRows[0].Add(row1);
UltraGrid grid = new UltraGrid();
grid.DataSource = ds;
I tested this code out and it appears to work fine for me. I had to make some small modificatios to get it to complie, though.
First, I had to change:
row11.GetChildRows[0].Add(row1);
to
row11.GetChildRows(0).Add(row1);
I assume that must be a typo in your post.
The only other thing I did was I put a grid on the form at design-time instead of creating the grid in code. The code you have here just creates the grid in code and it is never displayed or parented to any form, so it's impossible to know if it worked or not.