Thanks the retreive structure makes the grid show everything, so atleast I can now populate the grid.
However what I really want to be able to do is do what I did when using datasets as the datasource to a grid, in that
I had a grid user control that had various methods that would add columns to the grid such as
public void CTLAddTextColumn (string Caption, string DataMember, int Width, bool Visible)
{
Janus.Windows.GridEX.GridEXColumn myCol = new Janus.Windows.GridEX.GridEXColumn();
try
{
myCol.Caption = Caption;
myCol.Width = Width;
myCol.Visible = Visible;
myCol.DataMember = DataMember;
myCol.Key = DataMember;
myCol.ColumnType = Janus.Windows.GridEX.ColumnType.Text;
myCol.EditType = Janus.Windows.GridEX.EditType.NoEdit;
this.RootTable.Columns.Add(myCol);
}
catch (Exception ex)
{
throw new Exception("Unable to add text column - " + ex.Message);
}
}
where Caption would be the caption for the column and DataMember was the name of the column in the dataset. I would then just drop the control onto a form and in the form's load event I would set up the columns by writing one line of code for each column I wanted. I would then bing the form to a dataset (that contains each of the DataMembers required)
I would like to continue to use this approad but with collections as the datasource not a dataset.
Is this possible with collections?