ASP.NET MVC 3이 설치된 컴퓨터에 ASP.NET MVC 4 Beta를 설치 한 후 다음 예외가 발생합니다.
System.InvalidCastException이 사용자 코드에 의해 처리되지 않았습니다. Message = [A] System.Web.WebPages.Razor.Configuration.HostSection을 [B] System.Web.WebPages.Razor.Configuration.HostSection으로 캐스팅 할 수 없습니다. 유형 A는 'C : \ Windows \ Microsoft.Net \ assembly \ GAC_MSIL \ System'위치의 'Default'컨텍스트에서 'System.Web.WebPages.Razor, Version = 1.0.0.0, Culture = neutral, PublicKeyToken = 31bf3856ad364e35'에서 시작됩니다. .Web.WebPages.Razor \ v4.0_1.0.0.0__31bf3856ad364e35 \ System.Web.WebPages.Razor.dll '. 유형 B는 'C : \ Windows \ Microsoft.Net \ assembly \ GAC_MSIL \ System'위치의 'Default'컨텍스트에있는 'System.Web.WebPages.Razor, Version = 2.0.0.0, Culture = neutral, PublicKeyToken = 31bf3856ad364e35'에서 시작됩니다. .Web.WebPages.Razor \ v4.0_2.0.0. 0__31bf3856ad364e35 \ System.Web.WebPages.Razor.dll '. Source = System.Web.WebPages.Razor
StackTrace :
System.Web.WebPages.Razor.WebRazorHostFactory.GetRazorSection (String virtualPath) at System.Web.WebPages.Razor.WebRazorHostFactory.CreateHostFromConfig (String virtualPath, String physicalPath) at System.Web.WebPages.Razor.RazorBuildProvider.GetHostFromConfig () at System.Web.WebPages.Razor.RazorBuildProvider.CreateHost () at System.Web.WebPages.Razor.RazorBuildProvider.EnsureGeneratedCode () at System.Web.WebPages.Razor.RazorBuildProvider.get_CodeCompilerType () at System.Web.Compilation.BuildProvider. System.Web.Compilation.BuildProvidersCompiler.ProcessBuildProviders ()의 System.Web.Compilation.BuildProvidersCompiler.PerformBuild ()의 System.Web.Compilation.BuildManager에있는 GetCompilerTypeFromBuildProvider (BuildProvider buildProvider).System.Web.Compilation.BuildManager.GetVPathBuildResultInternal (VirtualPath virtualPath, Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate)의 CompileWebFile (VirtualPath virtualPath) at System.Web.Compilation.PathWithPath.GetVPathBuildResult , Boolean noBuild, Boolean allowCrossApp, Boolean allowBuildInPrecompile, Boolean throwIfNotFound, Boolean ensureIsUpToDate) at System.Web.Compilation.BuildManager.GetVirtualPathObjectFactory (VirtualPath virtualPath, HttpContext context, Boolean allowCrossApp, Boolean throwIfNotFound) at System.Web. System.Web.Mvc.BuildManagerViewEngine의 Web.Mvc.IBuildManager.FileExists (String virtualPath).System.Web.Mvc.VirtualPathProviderViewEngine.GetPathFromGeneralName (ControllerContext controllerContext, List`1 위치, String name, String controllerName, String areaName, String cacheKey, String [] & searchedLocations)의 FileExists (ControllerContext controllerContext, String virtualPath). System.Web.Mvc.VirtualPathProviderViewEngine.FindView의 Mvc.VirtualPathProviderViewEngine.GetPath (ControllerContext controllerContext, String [] locations, String [] areaLocations, String locationsPropertyName, String name, String controllerName, String cacheKeyPrefix, Boolean useCache, String [] & searchedLocations) (ControllerContext controllerContext, String viewName, String masterName, Boolean useCache) at System.Web.Mvc.ViewEngineCollection. <> c__DisplayClassc.b__b (IViewEngine e) at System.Web.Mvc.ViewEngineCollection.Find (Func`2 lookup, Boolean trackSearchedPaths) at System.Web.Mvc.ViewEngineCollection.FindView (ControllerContext controllerContext, String viewName, String masterName) at System.Web.Mvc .ViewResult.FindView (ControllerContext context) at System.Web.Mvc.ViewResultBase.ExecuteResult (ControllerContext context) at System.Web.Mvc.ControllerActionInvoker.InvokeActionResult (ControllerContext controllerContext, ActionResult actionResult) at System.Web.Mvc.ControllerActionInvoker. <> System.Web.Mvc.ControllerActionInvoker.InvokeActionResultFilter (IResultFilter filter, ResultExecutingContext preContext, Func`1 continuation)의 c__DisplayClass1c.b__19 () at System.Web.Mvc.ControllerActionInvoker. <> c__DisplayClass1c. <> c__DisplayClass1e.b__1b () at System.Web.Mvc.ControllerActionInvoker.InvokeActionResultWithFilters (ControllerContext controllerContext, IList`1 filters, ActionResult actionResult) at System.Web.Mvc.ControllerActionInvoker.InvokeAction (ControllerContext controllerContext, String actionName) at System.Web. [project_namespace] .Controllers.GlobalizationController.ExecuteCore ()의 Mvc.Controller.ExecuteCore ()는 [file_path]의 System.Web.Mvc.ControllerBase.Execute (RequestContext requestContext)는 System.Web.Mvc.ControllerBase.System.Web에 있습니다. Mvc.IController.Execute (RequestContext requestContext) at System.Web.Mvc.MvcHandler. <> c__DisplayClass6. <> c__DisplayClassb.b__5 () at System.Web.Mvc.Async.AsyncResultWrapper. <> c__DisplayClass1.b__0 () at System. Web.Mvc.Async.AsyncResultWrapper. <> c__DisplayClass8`1.b__7 (IAsyncResult _) at System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncResult`1.End () at System.Web.Mvc.MvcHandler. <> c__DisplayClasse.b__d () at System.Web.Mvc.SecurityUtil.b__0 (Action f) at System.Web.Mvc.SecurityUtil.ProcessInApplicationTrust (Action action) at System.Web.Mvc.MvcHandler.EndProcessRequest (IAsyncResult asyncResult) at System.Web.Mvc.MvcHandler. System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute ()의 System.Web.IHttpAsyncHandler.EndProcessRequest (IAsyncResult 결과) System.Web.HttpApplication.ExecuteStep (IExecutionStep 단계, Boolean & completedSynchronously)Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncResult`1.End () at System.Web.Mvc.MvcHandler. <> c__DisplayClasse.b__d () at System.Web.Mvc.SecurityUtil.b__0 (Action f) at System.Web. System.Web.Mvc.MvcHandler.EndProcessRequest (IAsyncResult asyncResult)의 Mvc.SecurityUtil.ProcessInApplicationTrust (Action action) at System.Web.Mvc.MvcHandler.System.Web.IHttpAsyncHandler.EndProcessRequest (IAsyncResult result) at System.Web.HttpApplication. CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute () at System.Web.HttpApplication.ExecuteStep (IExecutionStep 단계, Boolean & completedSynchronously)Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncResult`1.End () at System.Web.Mvc.MvcHandler. <> c__DisplayClasse.b__d () at System.Web.Mvc.SecurityUtil.b__0 (Action f) at System.Web. System.Web.Mvc.MvcHandler.EndProcessRequest (IAsyncResult asyncResult)의 Mvc.SecurityUtil.ProcessInApplicationTrust (Action action) at System.Web.Mvc.MvcHandler.System.Web.IHttpAsyncHandler.EndProcessRequest (IAsyncResult result) at System.Web.HttpApplication. CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute () at System.Web.HttpApplication.ExecuteStep (IExecutionStep 단계, Boolean & completedSynchronously)b__0 (Action f) at System.Web.Mvc.SecurityUtil.ProcessInApplicationTrust (Action action) at System.Web.Mvc.MvcHandler.EndProcessRequest (IAsyncResult asyncResult) at System.Web.Mvc.MvcHandler.System.Web.IHttpAsyncHandler.EndProcessRequest ( IAsyncResult 결과) at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute () at System.Web.HttpApplication.ExecuteStep (IExecutionStep step, Boolean & completedSynchronously)b__0 (Action f) at System.Web.Mvc.SecurityUtil.ProcessInApplicationTrust (Action action) at System.Web.Mvc.MvcHandler.EndProcessRequest (IAsyncResult asyncResult) at System.Web.Mvc.MvcHandler.System.Web.IHttpAsyncHandler.EndProcessRequest ( IAsyncResult 결과) at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute () at System.Web.HttpApplication.ExecuteStep (IExecutionStep step, Boolean & completedSynchronously)System.Web.HttpApplication.ExecuteStep (IExecutionStep step, Boolean & completedSynchronously)의 HttpApplication.IExecutionStep.Execute ()System.Web.HttpApplication.ExecuteStep (IExecutionStep step, Boolean & completedSynchronously)의 HttpApplication.IExecutionStep.Execute ()
이것은 나를 완전히 차단하고 베타를 유지하고 싶지만 예외를 제거하기 위해 완전히 제거해야 할 수도 있습니다.