DropDownList1用了Atlas后,为什么不能增加选项了。
用户控件里的代码 ddl.ascx
<table>
<tr>
<td>
<asp:DropDownList ID= "DropDownList1 " runat= "server " AutoPostBack= "True " OnSelectedIndexChanged= "DropDownList1_SelectedIndexChanged ">
</asp:DropDownList> <asp:RequiredFieldValidator ID= "RequiredFieldValidator2 " runat= "server " ControlToValidate= "DropDownList1 "
ErrorMessage= "RequiredFieldValidator "> * </asp:RequiredFieldValidator> </td>
<td>
<atlas:UpdatePanel ID= "UpdatePanel1 " runat= "server ">
<ContentTemplate>
<asp:DropDownList ID= "DropDownList2 " runat= "server ">
</asp:DropDownList>
<asp:RequiredFieldValidator ID= "RequiredFieldValidator1 " runat= "server " ControlToValidate= "DropDownList2 "
ErrorMessage= "RequiredFieldValidator "> * </asp:RequiredFieldValidator>
</ContentTemplate>
<Triggers>
<atlas:ControlEventTrigger ControlID= "DropDownList1 " EventName= "SelectedIndexChanged " />
</Triggers>
</atlas:UpdatePanel>
</td>
</tr>
</table>
cs代码
SqlConnection con = new SqlConnection(ConfigurationManager.ConnectionStrings[ "publ "].ConnectionString);
&n