views:

287

answers:

3

I have an ASP.NET 3.5 web application which works perfectly fine on my local machine and when I deploy it on my Windows 2008 server. I am getting the following javascript error:

Message: Sys.WebForms.PageRequestManagerServerErrorException: An unknown error occurred while processing the request on the server. The status code returned from the server was: 500
Line: 4723
Char: 21
Code: 0
URI: http://localhost/ScriptResource.axd?d=e1Gld4LGHLsC4rWqevEI8zAMJKoVcCEVHBjdJIxcQLO9of6t7nNopbI1YyxJTv1QbaxN_lTSoz5Ly-VjBRHp08Mf3xxg5V9i5Z0AiXIkZRY1&t=6af1de90

I have a utility which can decrypt the URI and tell exactly what file is missing and it tunrns out that the file is ZSystem.Web.Extensions,3.5.0.0,,31bf3856ad364e35|MicrosoftAjax.debug.js|. Why am I not able to load this js file? Any help?

A: 

Possible options:

  1. You've not installed .NET Framework SP1 on your server, so it can't find the 3.5 assemblies to generate the MsAjax file.
  2. You've deployed your web.config file with <compilation debug="true"> while IIS has been configured to compile it in release mode.
Zhaph - Ben Duguid
A: 

I have run into a similar problem before when the development and production machines are set for two different time zones. When ASP.NET AJAX tries to load a script resource from an assembly, the last modified date/time of the assembly is validated. If the local time of the production server is "earlier" than the last modified date/time of the assembly, then an ArgumentOutOfRange exception is generated by ASP.NET AJAX when processing the request.

Really difficult to debug since the problem eventually resolves itself.

I suppose this might be possible with a System assembly if Copy-Local is set to true.

Michael Petito
A: 

I was using some third party web services and the problem was with the following xml tag in the web.config:

<extendedProtectionPolicy policyEnforcement="Never" />

Once I removed this tag the error went away

Kumar