Can I read ajaxRequest arguments in master page OnInit

2 posts, 0 answers
  1. Thad
    Thad avatar
    106 posts
    Member since:
    Sep 2010

    Posted 08 Nov 2012 Link to this post

    Hello,

    I am firing an ajaxRequest and need to capture the arguments from within the OnInit of my master page.  This is because the page lifecycle fires the AjaxRequestHandler after the page has already loaded and I need to set global values prior to any page load.  I'm trying to avoid having to reload the pages by invoking a delegate.

    Is it possible to read the arguments in server code anywhere but in the event handler?

    Request.Form["__EVENTTARGET"] is "ctl00_rsmMain" and I can't find the property in the ScriptManager object.

    Thanks!!
    Thad
  2. Thad
    Thad avatar
    106 posts
    Member since:
    Sep 2010

    Posted 12 Nov 2012 Link to this post

    Figured this out.  The answer was staring me in the face I just didn't see the forest for the trees...

    string postbackArgument = Request.Form["__EVENTARGUMENT"];

    Sorry for wasting everyone's time!
    Thad
  3. UI for ASP.NET Ajax is Ready for VS 2017
Back to Top