gpt4 book ai didi

c# - 找不到方法 : '!!0[] System.Array.Empty()'

转载 作者:IT王子 更新时间:2023-10-29 03:34:35 28 4
gpt4 key购买 nike

我使用 VS 2015 RC 和 MVC 模板创建了一个新应用程序,但没有修改任何代码行,我遇到了这个错误:

Method not found: '!!0[] System.Array.Empty()'.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.MissingMethodException: Method not found: '!!0[] System.Array.Empty()'.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:


[MissingMethodException: Method not found: '!!0[] System.Array.Empty()'.]
SAASApp.BundleConfig.RegisterBundles(BundleCollection bundles) in C:\Proyectos\SAASApp\SAASApp\App_Start\BundleConfig.cs:29
SAASApp.MvcApplication.Application_Start() in C:\Proyectos\SAASApp\SAASApp\Global.asax.cs:18

[HttpException (0x80004005): Method not found: '!!0[] System.Array.Empty()'.]
System.Web.HttpApplicationFactory.EnsureAppStartCalledForIntegratedMode(HttpContext context, HttpApplication app) +483
System.Web.HttpApplication.RegisterEventSubscriptionsWithIIS(IntPtr appContext, HttpContext context, MethodInfo[] handlers) +118
System.Web.HttpApplication.InitSpecial(HttpApplicationState state, MethodInfo[] handlers, IntPtr appContext, HttpContext context) +176
System.Web.HttpApplicationFactory.GetSpecialApplicationInstance(IntPtr appContext, HttpContext context) +350
System.Web.Hosting.PipelineRuntime.InitializeApplication(IntPtr appContext) +305

[HttpException (0x80004005): Method not found: '!!0[] System.Array.Empty()'.]
System.Web.HttpRuntime.FirstRequestInit(HttpContext context) +661
System.Web.HttpRuntime.EnsureFirstRequestInit(HttpContext context) +96
System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest wr, HttpContext context) +189

我第一次遇到这种情况,所以我现在卡住了

最佳答案

我在生产服务器上遇到过这种情况,而在开发机器上一切正常。

在目标机器上安装 .NET Framework 4.6 已解决问题。

关于c# - 找不到方法 : '!!0[] System.Array.Empty()' ,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31253747/

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com