By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
458,060 Members | 1,248 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 458,060 IT Pros & Developers. It's quick & easy.

Dynamic Troubles

P: n/a
Does anyone know how I can bind these dropdowns to a

HtmlTable tbl = new HtmlTable();
HtmlTableRow tr = new HtmlTableRow();
HtmlTableCell td1 = new HtmlTableCell();
HtmlTableCell td2 = new HtmlTableCell();
HtmlTableCell td3 = new HtmlTableCell();
HtmlTableCell td4 = new HtmlTableCell();

// Create a textbox and a dropdown to hold the values
td2.Controls.Add(new TextBox());
td4.Controls.Add(new DropDownList());

// Name the objects
td2.ID = "txtCassette" +(i+1);
td4.ID = "ddlDenomination" +(i+1);

// Put the text in the empty cells
td1.InnerHtml = "Cassette #" +(i+1);
td3.InnerHtml = "Denomination";

// Add the cells to the row

// Add the row to the table

// Add the table to the placeholder

--This is the part that is broke that I need help with--
//ddlDenomination(i).DataSource = cmd.ExecuteReader();
//ddlDenomination(i).DataTextField = "name";
//ddlDenomination(i).DataValueField = "denominationid";

Jul 19 '05 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.