views:

361

answers:

2

What is updated when an Update is triggered? What goes to the server? What comes back?

I was under the impression that only the content of the panel was transmitted to the server and back (without touching anything in the page outside the panel), but I'm experiencing strange results, probably because I don't really understand how it works exactly.

Can someone provide an easy explanation as to how exactly it works?

+1  A: 

The post that goes to the server contains pretty much all the information of the post, including the viewstate. The difference is on what is actually returned back to the browser. To process the request, the full page is instantiated, if anything is updated outside the update panel, then you can get some ugly errors.

Update 1: this is different to other ajax approaches, that only send the bit of info needed and doesn't use viewstate i.e. autocompleteextender of the ajax control toolkit - look for json, ajax requests, and other related info.

It might work for you, but you are correct to look into understanding what is going on, that way you need when it is appropriate to just other solutions instead.

eglasius
+1  A: 

What is generated is a form submit through AJAX, which means essentially XML HTTP in the browser. When it hits the server, the server sees it as an AJAX call and it routes the Request to the correct method.

As for precisely what is sent, it is anything that the form submit should send, which can very well be information outside of the UpdatePanel. the sever then figures out what to work with and sends back a Response.

This is all well and good as theory, but you are dealing with problems not theory. What strangeness are you experiencing? If you can post, we can focus on the particulars of the problem.

Gregory A Beamer
Thanks for the reply, I'm experiencing this problem: http://stackoverflow.com/questions/591556
Juan Manuel
Added info in the other thread.
Gregory A Beamer