Both WebResource.axd and ScriptResource.axd give an error at System.Web.HttpCachePolicy.UtcSetLastModified(DateTime utcDate) method, as shown below:
[ArgumentOutOfRangeException: Specified argument was out of the range of valid values.
Parameter name: utcDate]
System.Web.HttpCachePolicy.UtcSetLastModified(DateTime utcDate) +3258643
System.Web.HttpCachePolicy.SetLastModified(DateTime date) +47
System.Web.Handlers.ScriptResourceHandler.PrepareResponseCache
(HttpResponse response, Assembly assembly) +194
System.Web.Handlers.ScriptResourceHandler.ProcessRequest
(HttpContext context) +1154
System.Web.Handlers.ScriptResourceHandler.System.Web.IHttpHandler.
ProcessRequest(HttpContext context) +4
System.Web.CallHandlerExecutionStep.System.Web.HttpApplication
.IExecutionStep.Execute() +154
System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +64
First, look for the simple. If it's your machine's date time is in the past (or the future), then it is easy to fix. Just change your system clock.
In our case, it is not that straight forward. We have moved the time forward for a while, and ASP .NET 2.0 SP1 was installed while the time is in the future. So basically the assemblies and GAC modified date time is in the future. AJAX does not like it. I guess it is a bug.
We wanted to uninstall and reinstall SP1, but windows does not allow us to remove it. So we click "change" instead of "remove" in Add/Remove programs. Not sure what did windows do, but magically it works. It probably update all the installed dlls, so the modified date times are corrected.
Otherwise, we may have to "touch" all the files... :(
HAPPY NEW YEAR :)
ReplyDeleteThis solution is working in our case. We tried to resolve this issue for last 2 days and finally got the solution. Thank you very much !!
ReplyDeleteWorked a treat, thank you very much!!
ReplyDeleteThank you for the tips, you saved me a lot of time.
ReplyDeleteI pay my respects to you, great article
ReplyDeleteImmensely useful! This just saved me loads of time and frustration trying to work out why we were getting JS errors all over our app during some testing that required changing the server time... thank you so much :D
ReplyDeleteFeeling very happy , had wasted so much of time on this .....Was juggling around with mapping of Webresource file with WebDevelopment server issues for improper rendering of tree control.
ReplyDeleteThanks a ton !
This comment has been removed by the author.
ReplyDeletethanks!
ReplyDeleteThis also worked for me except I had to do a repair on .NET 3.5 SP1 instead. Thanks!
ReplyDeleteThank you,
ReplyDeleteIt works for us. Thanx a lot
Hey Gypsy... thanks much for the article... turns out we had the same problem!
ReplyDelete-sri
dasdasd
ReplyDeleteI had this same problem earlier... but forgot how I fixed it. Now I came across your blog. Helped a lot! Awesome!
ReplyDeletei changed the system date, the error disappeared !
ReplyDeleteNice. You have saved me a lot of time. =)
ReplyDeleteThank you so much! :) This solved my problem.
ReplyDeleteHii
ReplyDeletethis blog is really helpful to me
There's one more approach that worked for me.
ReplyDeletetry running: for %i in (*.dll) do copy /b %i+,,
in the Bin directory of the application
it means that the assembly was built in future according to the webserver, the command above will 'touch' them so they appear to be of current date
http://stackoverflow.com/questions/2782329/specified-argument-was-out-of-the-range-of-valid-values-parameter-name-utcdate