J
Jim Bancroft
Hi everyone,
I'm binding an ArrayList to a DataGrid for the first time (I'm used to
binding DataSets and DataTables) and I was wondering if I could somehow
"name" the ArrayList, so that I can refer to it as a DataField in an
asp:BoundColumn?
In essence, I'm doing this:
ArrayList Arr1 = new ArrayList();
Arr1.Add("John");
Arr1.Add("Melissa");
Arr1.Add("Tim");
MyDataGrid.DataSource = Arr1;
MyDataGrid.DataBind();
Now I'd like to use an <asp:BoundColumn> control in the DataGrid, but I
don't know what the DataField value is for the ArrayList I just added. Can
I somehow associate a DataField value with the ArrayList?
I'm binding an ArrayList to a DataGrid for the first time (I'm used to
binding DataSets and DataTables) and I was wondering if I could somehow
"name" the ArrayList, so that I can refer to it as a DataField in an
asp:BoundColumn?
In essence, I'm doing this:
ArrayList Arr1 = new ArrayList();
Arr1.Add("John");
Arr1.Add("Melissa");
Arr1.Add("Tim");
MyDataGrid.DataSource = Arr1;
MyDataGrid.DataBind();
Now I'd like to use an <asp:BoundColumn> control in the DataGrid, but I
don't know what the DataField value is for the ArrayList I just added. Can
I somehow associate a DataField value with the ArrayList?