开发者

Exception when VS 2010 ASP.NET Development Server Serves Static Files

I'm building an ASP.NET MVC 2 site with Visual Studio 2010 Beta 2.

Out of nowhere none of my images or css started showing up. If I navigate directly to the resources in the browser I see this exception message:

Specified argument was out of the range of valid values. Parameter name: utcDate

Stack Trace:

[ArgumentOutOfRangeException: Specified argument was out of the range of valid values. Parameter name: utcDate]

System.Web.HttpCachePolicy.UtcSetLastModified(DateTime utcDate) +3038942

System.Web.StaticFileHandler.ProcessRequestInternal(HttpContext context, String overrideVirtualPath) +1130 System.Web.DefaultHttpHandler.BeginProcessRequest(HttpContext context, AsyncCallback callb开发者_如何学Pythonack, Object state) +347

System.Web.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() +8683736 System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously) +184

Some Notes:

Already tried restarting vs 2010, closing all the webserver instances, restarting IIS.


Fixed this by setting my computer's clock data way into the future, build the project in debug mode, and then moved the time back.

From googling around I found this is because your trying to load assemblies that were last modified in the future. Time travel coding basically.

The other problem I had was once I set the time into the future, my VS2010 evaluation period expired.


Lol, this was because of daylight savings time which I completely forgot about.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜