更新面板需要很长时间才能做出响应 [英] Update panel taking long time to respond

查看:85
本文介绍了更新面板需要很长时间才能做出响应的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用fancybox登录div中的更新面板,但需要20秒才能对Button单击做出响应
如何解决他的问题,请帮助任何人...


I''m using update panel within my fancybox login div but it takes 20 secs to respond on Button click
how to resolve his issue plz help me anyone...


<div style="display: none;"><div id="001" style="width:400px;height:275px; overflow:hidden; background-image:removed(image/bg.jpg.pagespeed.ce.hBQipZqWVe.jpg);">
   <asp:ScriptManager ID="ScriptManager1" runat="server">
      </asp:ScriptManager>
      
  <asp:UpdatePanel ID="UpdatePanel1" runat="server" UpdateMode="Conditional">
  <ContentTemplate>
  <table width="400px" height="110px" class="align" style="font-family: Arial, Helvetica, sans-serif; color: #000000; font-size: medium">
  <br />
   <center>
       
        <font color="Green">   <h1>
               Log in</font></h1></center>
   
    
<font style="font-family: Arial, Helvetica, sans-serif; font-size:15px; color:black;"> Email:</font> <fieldset>   <asp:TextBox ID="TextBox1" runat="server"  Width="200px" Height="30px"></asp:TextBox></fieldset>  
<font style="font-family: Arial, Helvetica, sans-serif; font-size:15px; color:black;"> Password: </font>  <fieldset><asp:TextBox ID="TextBox2" runat="server"  TextMode="Password"  Width="200px" Height="30px" ></asp:TextBox></fieldset>
      <asp:Button ID="Button2" runat="server"  Text="Login" onclick="Button2_Click" CssClass="sub5"/>  
    <br />
    <br />
    <asp:Label ID="Label1" runat="server"></asp:Label>
    
   
   </table>
   </ContentTemplate>
<Triggers>
 <asp:AsyncPostBackTrigger ControlID="Button2"

 EventName="Click" />
</Triggers>
   </asp:UpdatePanel>
    
   
  
   
   </div></div>

推荐答案

由于您的按钮位于UpdatePanel内部,因此我倾向于认为默认情况下它将执行异步回发,因此您不必指定任何内容触发器.您可以将ChildrenAsTriggers属性设置为"true",以在单击updatepanel中的按钮时引起回发.
since your button is inside the UpdatePanel, I am tempted to think that it would do an async post back by default so you don''t have to specify any triggers. You can set the ChildrenAsTriggers property to "true" to cause a postback when the button inside the updatepanel is clicked.


这篇关于更新面板需要很长时间才能做出响应的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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