views:

345

answers:

3

Has anyone run into this error message before when using a timer on an ASP.Net page to update a datagrid every x seconds? Searching google yielded this blog entry

and many more but nothing that seems to apply to me yet. The full text of the error message below:

Sys.WebForms.PageRequestManagerParserErrorException: The message received from the server could not be parsed. Common causes for this error are when the response is modified by calls to Response.Write(), response filters, HttpModules, or server trace is enabled.

A: 

Regarding the formatting of your post: If you use the quote-button instead of code-button, people do not have to scroll to see the complete error message.

Espo
+2  A: 

Many issues can cause that error. It's usually a Response.Write call, but anything that modifies the response can cause it.

We probably won't be able to help you unless you post some pertinent code-behind.

Dave Ward
+1  A: 

The RoleProvider sets a cookie to cache role information in a cookie. When the cookie resets during an asynch post back from AJAX, you will get this error. The solution is to either set the cookieTimeout in the roleManager section of your web.config to a very large number of minutes, or set the cacheRolesInCookie=false.

This was a known bug in AJAX 1.0 Extensions. I'm not sure if it was fixed in future releases, and I should have mentioned that I was using AJAX 1.0 extensions in VS2008 targeting the 2.0 framework.

Happy programming!

JasonS