protected void DropDownList1_SelectedIndexChanged(object sender, EventArgs e)
{
SqlConnection conn1 = new SqlConnection(System.Configuration.ConfigurationManager.AppSettings["connstring"]);
string id = DropDownList1.SelectedValue.ToString();
SqlParameter[] parm = new SqlParameter[]
{
new SqlParameter("@admin_psortname", id)
};
DataSet ds2 = SqlHelper.ExecuteDataset(conn1, CommandType.StoredProcedure, "select_zsort_bypid", parm);
DropDownList2.DataSource = ds2.Tables[0].DefaultView;
this.DropDownList2.DataTextField = "admin_zsortname";
this.DropDownList2.DataValueField = "admin_zsortname";
DropDownList2.DataBind();
}
{
SqlConnection conn1 = new SqlConnection(System.Configuration.ConfigurationManager.AppSettings["connstring"]);
string id = DropDownList1.SelectedValue.ToString();
SqlParameter[] parm = new SqlParameter[]
{
new SqlParameter("@admin_psortname", id)
};
DataSet ds2 = SqlHelper.ExecuteDataset(conn1, CommandType.StoredProcedure, "select_zsort_bypid", parm);
DropDownList2.DataSource = ds2.Tables[0].DefaultView;
this.DropDownList2.DataTextField = "admin_zsortname";
this.DropDownList2.DataValueField = "admin_zsortname";
DropDownList2.DataBind();
}