c# - 单击按钮后 ASP.net 页面刷新
问题描述
我只想在单击 ASP 按钮“VALIDER”后刷新页面。
<asp:Button Text="VALIDER" ID="lbSuiteOuvragesNContr"
runat="server" onclick="lbSuiteOuvragesNContr_Click" />
protected void lbSuiteOuvragesNContr_Click(object sender, EventArgs e)
{
BoProcesVerbaux.ModifierInspectionGpeOuvrageComposition(uc_OuvragesNonControlesV41.ListeInspection);
this.IdPv = IdProcesVerbal;
uc_OuvragesNonControlesV42.IdPV = idPv;
InitialiserPage(this.IdPv);
}
解决方案
我不太明白您的服务器事件在做什么,您可以尝试刷新页面。
Page.Response.Redirect(Page.Request.Url.ToString(), true);
但也许您只是想创建完整的回帖或使用更新面板来更新您的视图?
推荐阅读
- twilio - Twilio TaskRouter 无服务器预留功能
- dart - 如何打印枚举的值?
- uml - 专业化或扩展点用例
- reactjs - 如何制作别名以指向外部文件夹?
- android - 出了点问题 android studio 应用程序刚刚退出
- c# - SceneManager.LoadScene 不加载场景
- android - 如何添加静态项目,例如“添加新联系人”,始终作为回收站视图的第一项?
- python - 避免函数中的冗余循环
- python - 我们可以复制别人的声音并在python中用作说话功能吗?
- java - AudioFormat 为 FLAC 文件返回异常但适用于 WAV 文件?