Hello,
I have a webform that has 3 dropdownlist controls and I can't seem to get them populated. They are databound and the build generates no errors.
Can someone look at my code and let me know what's missing?
Thanks a lot!!!
Webform:
|
|
|
Code Behind:
public class Profile : System.Web.UI.Page
{
protected System.Data.SqlClient.SqlConnection conn;
protected System.Web.UI.WebControls.DropDownList dd1;
protected TimeSheet1.dsLineItem dsLineItem1;
protected System.Data.SqlClient.SqlDataAdapter daLineItem;
protected System.Data.SqlClient.SqlCommand sqlSelectCommand1;
protected System.Web.UI.WebControls.DropDownList dd2;
protected TimeSheet1.dsComponent dsComponent1;
protected System.Data.SqlClient.SqlDataAdapter daComponent;
protected System.Data.SqlClient.SqlCommand sqlSelectCommand2;
protected System.Web.UI.WebControls.DropDownList dd3;
protected TimeSheet1.dsActivity dsActivity1;
protected System.Data.SqlClient.SqlDataAdapter daActivity;
protected System.Data.SqlClient.SqlCommand sqlSelectCommand3;
private void Page_Load(object sender, System.EventArgs e)
{
}
#region Web Form Designer generated code
private void dd1_SelectedIndexChanged(object sender, System.EventArgs e)
{
daLineItem.Fill(dsLineItem1,"LI_ID");
dd1.DataBind();
}
private void dd2_SelectedIndexChanged(object sender, System.EventArgs e)
{
daComponent.Fill(dsComponent1, "Component");
dd2.DataBind();
}
private void dd3_SelectedIndexChanged(object sender, System.EventArgs e)
{
daActivity.Fill(dsActivity1, "Abbrev");
dd3.DataBind();
}
}
}