Click here to Skip to main content
15,892,059 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
I am using an Update Panel and inside it I have a div in which I show a message when the repeater's Item Command is fired. The div is visible false in beginning.

ASP.NET
<div id="divCommentsMsg" class="form_popup_Msg" visible="false"  runat="server">
        <asp:Label ID="lblCommentsMsg" runat="server"></asp:Label>
  </div>


It is made visible on repeater's ItemCommand. To fade it out I use:

JavaScript
$("#ctl00_ContentPlaceHolder1_ctrlComments_divCommentsMsg").delay(3000).fadeOut(100);


The div becomes visible but doesn't fade out. What should I do ?
Posted

 
Share this answer
 
v3
Comments
Member 8491154 20-Dec-12 0:02am    
your third link solved my problem :) ty
Member 8491154 20-Dec-12 0:07am    
other links are not opening
Surendra0x2 20-Dec-12 4:33am    
My pleasure bro :)
Hi,

Please view the following link for your reference.
UpdatePanel Breaks JQuery Script

this will show you the path how to use for Update panel.

Thanks
 
Share this answer
 
Comments
Member 8491154 19-Dec-12 6:43am    
can you please provide a code snippet for my question on how do i proceed?
Hi,
You can do two things,

First, you can get the divCommentsMsg div by following way and fade it out:
JavaScript
$("#<%# divCommentsMsg.CliendID %>").delay(3000).fadeOut(100);


Second, you can get that div by its class. Make sure class of that div is not used anywhere else.
JavaScript
$(".form_popup_Msg").delay(3000).fadeOut(100);


I hope this will help.
Thanks :)
 
Share this answer
 
Comments
Member 9581488 19-Dec-12 16:10pm    
$("#<%# divCommentsMsg.CliendID %>").delay(3000).fadeOut(100);
should be
$("#<%= divCommentsMsg.CliendID %>").delay(3000).fadeOut(100);
Sk. Tajbir 19-Dec-12 16:18pm    
Thats great..:)

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900