c# - 无法加载文件或程序集 Microsoft.VisualStudio.Shell,版本 = 2.0.0.0

标签 c# .net .net-4.5.2

我上周在我的 R2 开发服务器上安装了 4.5.2 框架,从那以后一直出现这个错误。这些文件不包含对 VisualStudio.Shell 的引用。有什么想法吗?

Parser Error Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately.

Parser Error Message: Reference.svcmap: Could not load file or assembly 'Microsoft.VisualStudio.Shell, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot find the file specified.

Source Error:

[No relevant source lines]

Source File: /App_WebReferences/ClientApplicationServer/ Line: 1

Assembly Load Trace: The following information can be helpful to determine why the assembly 'Microsoft.VisualStudio.Shell, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' could not be loaded.

最佳答案

所以我花了大约 2 天时间试图弄清楚到底发生了什么......

我能够修复它的方法是将 Microsoft.VisualStudio.Shell 添加到 C:\Windows\程序集

但唯一的方法是使用 gacutil .

gacutil -i Microsoft.VisualStudio.Shell.dll

这对我来说已经解决了。希望它能帮助遇到同样问题的人。

关于c# - 无法加载文件或程序集 Microsoft.VisualStudio.Shell,版本 = 2.0.0.0,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/29607341/

相关文章:

.net - 如何在 Visual Studio 中选择 .NET 4.5.2 作为目标框架

c# - ajax 中的 get 请求到 Controller 操作不起作用?

c# - 如何从终结器中正确处理非托管资源的集合?

c# - Visual Studio : Setting a conditional breakpoint without setting an unconditional one first

c# - 列表列表的交集

c# - 从类型名称的字符串表示形式强制转换为类型

c# - 如何使用 C# 查找一个月中的第三个星期五?

c# - RabbitMQ:直接回复?

c# - mscorlib 5.0.5.0 中缺少 System.Security.Cryptography.RSA

windows-server-2012-r2 - 您可以在 Windows Server 2016 上安装 .NET 4.5 吗?