If for instance, I was to give a response back to an ASP.Net Update Panel page, but use Response.Write and then end it before anything was rendered, what is the minimum I would need to write in the Response.Write?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
If you take the following UpdatePanel …
… then click the button and view the response in Firebug, you’ll get something like this (I’ve truncated the viewstate and event validation to make it a bit more readable):
All that extra data is stuff that the
ScriptManagerneeds to rebuild the contents of the UpdatePanel: control ids, the page name, viewstate, etc.. This is what you’d have toResponse.Writemanually for theScriptManagerto be able to do its job.For details, see “ScriptManager Enables AJAX In Your Web Apps“. At the end of the section titled “Putting the AJAX in ASP.NET AJAX”, the author explains what’s going on: