Ajax, Post and whats sent

2 posts, 0 answers
  1. Mark
    Mark avatar
    12 posts
    Member since:
    Aug 2012

    Posted 03 Nov 2010 Link to this post

    Using fiddler and viewing whats being posted during an ajax post i can see the view state and then all the __event hidden fields. After that i can see the id's of controls and values e.g. ctl00_BodyContent_ConsentTree_ClientState=%7b%....

    Why are the ctl00_BodyContent_ConsentTree_ClientState... etc being added to whats being posted back?

    Are these controls duplicated in the viewstate thats being posted back?

    Can we send the post without them?

    I have read the article http://www.telerik.com/help/aspnet/ajax/ajxtelerikajax.html and viewed the text below. 

    So if we didn't post back the ctl00_BodyContent_ConsentTree_ClientState....etc we wouldn't be able to access there current values?

    Persistence of form values - all form values are sent to the server for processing during the AJAX request and are persisted between AJAX requests. All form controls can be referenced in the code-behind as if a postback occurred. This feature guarantees that your AJAX-enabled applications will not be limited to mere rendering of controls with AJAX, but can cover even the most complex scenario.  
  2. Cori
    Cori avatar
    562 posts
    Member since:
    Jul 2010

    Posted 04 Nov 2010 Link to this post

    Hello Mark,

    The way ASP.NET Ajax works, is that it posts back the entire form and only updates the area's that are enclosed in an UpdatePanel. It's exactly the same as a normal postback without the page "flash".  To answer your other questions, the controls are not duplicated and the postback cannot occur in any other way with ASP.NET Ajax.

    If you want to speed up you app or not have it post the entire page you can use the XmlHttpPanel, which uses callbacks and is faster than RadAjaxPanel.

    I hope that helps.
Back to Top