0
在這裏你可以看到我的html代碼。我需要運行OnSelectedIndexChanged事件,但我必須阻止回發所有頁面。我該怎麼辦?更新面板打破RadioButtonList的OnSelectedIndexChanged事件
<asp:UpdatePanel runat="server" ID="upRemittance">
<ContentTemplate>
<asp:RadioButtonList runat="server" ID="rblRemittance" AutoPostBack="True" OnSelectedIndexChanged="rblRemittance_OnSelectedIndexChanged">
</asp:RadioButtonList>
</ContentTemplate>
</asp:UpdatePanel>
RadioButtonList的裝訂方法:
List<remittance> remittances = _mainService.RemitanceActiveList().ToList();
if (remittances.Count > 0)
{
rblRemittance.DataSource = remittances;
rblRemittance.DataTextField = "BankName";
rblRemittance.DataValueField = "RemitanceId";
rblRemittance.DataBind();
}
什麼問題? –
刪除UpdatePanel – Roar
@YuriyRozhovetskiy OnSelectedIndexChanged事件不會被調用。 – cagin