AJAX Update Pannel

Discussion in 'ASP .Net' started by Andrew Robinson, Mar 22, 2007.

  1. I need to update a value outside of an update pannel from within code that
    originates inside of an update panel. Any way to make this happen?

    Specifically I have a status bar inside of a master page that needs to get
    updated after certain operations that are currently wrapped inside of an
    update pannel. This update does not need to be done async but currently,
    changes to the status bar are being lost.


    Thanks,
     
    Andrew Robinson, Mar 22, 2007
    #1
    1. Advertising

  2. You can use the Page Request Manager's EndRequestHandler event to execute
    some custom JavaScript after an AJAX call has completed.
    So something along these lines should do it:

    var prm = Sys.WebForms.PageRequestManager.getInstance();
    prm.add_endRequest(EndRequestHandler);
    function EndRequestHandler(sender, args)
    {
    $get("MyStatusBarDiv").innerText =
    $get("MyHiddenTextBoxFromInsideTheUpdatePanel").innerText
    }

    --
    I hope this helps,
    Steve C. Orr,
    MCSD, MVP, CSM, ASPInsider
    http://SteveOrr.net


    "Andrew Robinson" <> wrote in message
    news:...
    >I need to update a value outside of an update pannel from within code that
    >originates inside of an update panel. Any way to make this happen?
    >
    > Specifically I have a status bar inside of a master page that needs to get
    > updated after certain operations that are currently wrapped inside of an
    > update pannel. This update does not need to be done async but currently,
    > changes to the status bar are being lost.
    >
    >
    > Thanks,
     
    Steve C. Orr [MCSD, MVP, CSM, ASP Insider], Mar 23, 2007
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. A.M
    Replies:
    1
    Views:
    343
    avnrao
    May 14, 2004
  2. Replies:
    20
    Views:
    1,934
    d1srupt3r
    Mar 31, 2008
  3. darrel

    beginner AJAX questions (AJAX.net)

    darrel, Apr 27, 2006, in forum: ASP .Net
    Replies:
    5
    Views:
    2,462
    Flinky Wisty Pomm
    Apr 28, 2006
  4. jb
    Replies:
    2
    Views:
    448
  5. minnie
    Replies:
    1
    Views:
    737
    Andrew Thompson
    Dec 13, 2006
Loading...

Share This Page