Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
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.
 
<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:
 
$("#ctl00_ContentPlaceHolder1_ctrlComments_divCommentsMsg").delay(3000).fadeOut(100);
 
The div becomes visible but doesn't fade out. What should I do ?
Posted 19-Dec-12 0:11am
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 3

On ItemCommand a Postback happens hence..Jquery is not working..i also faced this prblm
when i was using Jquery toogle...
 
here i got this solution...
 
jquery toggle div disappearing after postback(Button click)[^]
 
-------
 
http://dotnet.dzone.com/news/conflicts-between-aspnet-ajax-0[^]
-----
http://stackoverflow.com/questions/256195/jquery-document-ready-and-updatepanels[^]
 
-----
 
Same issue--
 
http://stackoverflow.com/questions/3815119/how-to-fadeout-a-label-inside-a-update-panel-with-jquery-in-asp-net[^]
  Permalink  
v3
Comments
Member 8491154 at 20-Dec-12 0:02am
   
your third link solved my problem :) ty
Member 8491154 at 20-Dec-12 0:07am
   
other links are not opening
Surendra0x2 at 20-Dec-12 4:33am
   
My pleasure bro :)
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

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
  Permalink  
Comments
Member 8491154 at 19-Dec-12 6:43am
   
can you please provide a code snippet for my question on how do i proceed?
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

Hi,
You can do two things,
 
First, you can get the divCommentsMsg div by following way and fade it out:
$("#<%# 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.
$(".form_popup_Msg").delay(3000).fadeOut(100);
 
I hope this will help.
Thanks Smile | :)
  Permalink  
Comments
Member 9581488 at 19-Dec-12 16:10pm
   
$("#<%# divCommentsMsg.CliendID %>").delay(3000).fadeOut(100);
should be
$("#<%= divCommentsMsg.CliendID %>").delay(3000).fadeOut(100);
Sk. Tajbir at 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)

  Print Answers RSS
0 OriginalGriff 540
1 Sergey Alexandrovich Kryukov 407
2 Yogesh Kumar Tyagi 384
3 Prakriti Goyal 280
4 Maciej Los 205
0 OriginalGriff 6,632
1 Sergey Alexandrovich Kryukov 5,429
2 Maciej Los 3,474
3 Peter Leow 3,309
4 DamithSL 2,495


Advertise | Privacy | Mobile
Web03 | 2.8.140721.1 | Last Updated 19 Dec 2012
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100