问题描述
|
我有:
<asp:RadioButtonList ID=\"selectedYesNoQuestionBlock7\" runat=\"server\"
RepeatDirection=\"Horizontal\" OnSelectedindexChanged=\"Question7GotAnswered\">
<asp:ListItem Text=\"Yes\" Value=\"1\"></asp:ListItem>
<asp:ListItem Text=\"No\" Value=\"0\"></asp:ListItem>
</asp:RadioButtonList>
....
<div id=\"btCreate\" style=\"margin-left: 254px; margin-top: 10px;\">
<asp:Button runat=\"server\" Text=\"Categorize\" ID=\"btCategorize\" />
</div>
我想在选择列表项之后提交“ wothout”按钮。有可能吗?如何?
解决方法
将ѭ1设置为
AutoPostBack=\"true\"
<asp:RadioButtonList AutoPostBack=\"True\" ID=\"selectedYesNoQuestionBlock7\"
runat=\"server\" RepeatDirection=\"Horizontal\"
OnSelectedIndexChanged=\"Question7GotAnswered\">
...
</asp:RadioButtonList>
, 查看RadioButtonList
控件公开的事件,并将代码放入正确的事件处理程序中。我想您也应该将控件设置为TrueAutoPostBack
。