Hello i need to create from 1 to many new RadGrids based on the selection of an item/s from a static RadGrid, ie create a new "on the fly" RadGrid for every row item selected from a static RadGrid. I thought that by giving each new RadGrid a new RadGrid.ID, see below, that it might create a new RadGrid and that a new RadGrid would appear under the previously created RadGrids, ie appending new RadGrids under the previous created "otf" RadGrids. But i think i'm getting the understanding that i would need to create all of the potential new "otf" RadGrids in advance and manage the visibiliy of each one as needed. For example i would have to create a list of RadGrids in advance like RadGrid radgrid1; RadGrid radgrid2; RadGrid radgrid3; ......ect. Or is there a way to actually create a new RadGrid really genuinely from scratch on the fly?
private void DefineGridStructure2()
{
string txt = "TABLE1";
CustomQuery.
GetInfoSchema gis = new CustomQuery.GetInfoSchema();
string cs = "Data Source=DEVSQL.fhfb.gov;Initial Catalog=CustomQuery;Integrated Security=True";
DataTable dt = gis.GetTableInfo(cs, txt);
RadGrid grid = new RadGrid();
string sgridID="grid"+lblMessage.Text;
grid.ID = sgridID;
grid.AutoGenerateColumns =
true;
grid.DataSource = dt;
grid.DataBind();
Master.FindControl(
"mainContain").Controls.Add(grid);
string chktxt = lblMessage.Text;
}