如何从 UpdatePanel 中的按钮强制完全回发? [英] How do I force full post-back from a button within an UpdatePanel?

查看:26
本文介绍了如何从 UpdatePanel 中的按钮强制完全回发?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何从 UpdatePanel 中的按钮强制完全回发?

How do I force full post-back from a button within an UpdatePanel?

推荐答案

您可以使用 Triggers 属性的 UpdatePanel 以注册触发完整回发的操作.

You can use the Triggers property of the UpdatePanel to register actions that trigger a full postback.

向其添加 PostBackTrigger 对象属性,包含需要触发完整回发的控件的 ControlID.

Add a PostBackTrigger object to that property, containig the ControlID of the control which needs to trigger a full postback.

<asp:UpdatePanel ID="UpdatePanel1" UpdateMode="Conditional" runat="server">
    <ContentTemplate>
        ...
    </ContentTemplate>
    <Triggers>
        <asp:PostBackTrigger ControlID="myFullPostBackControlID" />
    </Triggers>
</asp:UpdatePanel>

这篇关于如何从 UpdatePanel 中的按钮强制完全回发?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆