UpdatePanel writeback error: Sys.WebForms.PageRequestManagerParserErrorException

Already looked at this: Sys.WebForms.PageRequestManagerParserErrorException - what it is and how to avoid it

The problem is that this only happens in my dev block. Two other developers are fine.

It is consistent and reproducible - I tried to delete temporary Internet files, deleted the obj and bin files and rebooted.

The answer is clearly truncated when I look at it in the debugger, when it gets into an error.

Where else do I need to check to clean / clean?

The error I see in the code is:

Microsoft JScript runtime error: Sys.WebForms.PageRequestManagerParserErrorException: messages received from the server cannot be analyzed. Common causes of this error are when the response is modified by calling Response.Write (), response filters, HttpModules, or server tracing. Details: Error parsing next to ' </tr> .

 _endPostBack: function PageRequestManager$_endPostBack(error, executor, data) { if (this._request === executor.get_webRequest()) { this._processingRequest = false; this._additionalInput = null; this._request = null; } var eventArgs = new Sys.WebForms.EndRequestEventArgs(error, data ? data.dataItems : {}, executor); Sys.Observer.raiseEvent(this, "endRequest", eventArgs); if (error && !eventArgs.get_errorHandled()) { throw error; // THIS IS WHERE THE ERROR IS THROWN } }, 

This is during the Ajax postback.

  • No calls to Response.Write.

  • I am using Cassini / VS 2010 Development Server, how do I know if there are filters?

  • Ditto

  • Server Trace Not Enabled

  • No calls to Server.Transfer

In firebug, I see that the response to the POST is truncated. The problem occurs in Firefox or IE, and I am a debugger in VS or not.

The problem will disappear if I switch to IIS Express in Visual Studio and then return when I return to the ASP.NET development server.

+4
source share
4 answers

After our conversation, my idea was that perhaps for some reason cassini cannot hold a large return mail field, and a large one is a viewstate.

So, if the viewstate is very large, perhaps this is a problem.

The second case may be if the view contains characters that for some time do not pass through a router or some kind of firewall and do not cut them as a possible attachment or virus.

Possible solutions: compressing the viewport and / or reducing it in smaller parts.

You can also download the latest Cassini release for developers, with many improvements at http://cassinidev.codeplex.com/ , possibly fixing this problem.

+2
source

I saw this problem before with Cassini. I solved this by adding the following to Web.config:

 <system.web> <httpModules> <add name="ScriptModule" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/> </httpModules> </system.web> 

Record above for version 1.0. Verify that the Version and PublickKeyToken attributes match the version of ASP.net Ajax you are using. You can also disable event checking on your page:

 enableEventValidation="false" 

Hope this helps!

+3
source

Do you use some kind of compression of the http module? It seems like using updated packages is having problems similar to yours. Please view this post .

If you are not using compression, perhaps another httpmodule-related error makes you suffer. Try adding this to your web page:

 enableEventValidation="false" 

Perhaps you could catch the exception with this code:

  protected void ScriptManager1_AsyncPostBackError(object sender, AsyncPostBackErrorEventArgs e) { ScriptManager1.AsyncPostBackErrorMessage = e.Exception.Message+e.Exception.StackTrace ; } <asp:ScriptManager ID="ScriptManager1" runat="server" OnAsyncPostBackError="ScriptManager1_AsyncPostBackError"> </asp:ScriptManager> 

Source for this last thing.

+2
source

Error:

 Sys.WebForms.PageRequestManagerServerErrorException: Sys.WebForms.PageRequestManagerServerErrorException: An unknown error occurred while processing the request on the server. The status code returned from the server was: 500 

decision:

 <add key="aspnet:MaxHttpCollectionKeys" value="100000"/ > 

Add a key in the application settings section.

-one
source

Source: https://habr.com/ru/post/1394046/


All Articles