c# – Visual Studio代码 – 添加引用错误

c# – Visual Studio代码 – 添加引用错误,第1张

概述当我在Visual Studio Code(v 0.1.0)编辑器中打开Visual Studio 2013 C#项目,下载链接 here时,我遇到了十几个错误: The type ‘Object’ is defined in the assembly that is not referenced. You must add reference to assembly ‘mscorlib, Ver 当我在Visual Studio Code(v 0.1.0)编辑器中打开Visual Studio 2013 C#项目,下载链接 here时,我遇到了十几个错误:

The type ‘Object’ is defined in the assembly that is not referenced.
You must add reference to assembly ‘mscorlib,Version=2.0.5.0,
Culture=neutral,PublicKeyToken=7cec85d7bea7798e,Retargetable=Yes’.
[my c# project name]

Project使用.NET Framework 4.5.在Visual Studio 2013中打开项目时自动引用的mscorelib.dll是Version = 4.0.0.0.

有没有办法配置VS2013项目,以便Visual Studio代码正确识别引用和框架版本?

系统:windows,未安装Visual Studio 2015组件.

解决方法 根据此StackOverflow answer,您可以尝试以下方法来解决您的问题:

I was able to fix this by issuing an update-package -reinstall command at the Package Manager Console.

总结

以上是内存溢出为你收集整理的c# – Visual Studio代码 – 添加引用错误全部内容,希望文章能够帮你解决c# – Visual Studio代码 – 添加引用错误所遇到的程序开发问题。

如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。

欢迎分享,转载请注明来源:内存溢出

原文地址: http://outofmemory.cn/langs/1231328.html

(0)
打赏 微信扫一扫 微信扫一扫 支付宝扫一扫 支付宝扫一扫
上一篇 2022-06-06
下一篇 2022-06-06

发表评论

登录后才能评论

评论列表(0条)

保存