c# - Microsoft.SqlServer.Smo 问题

标签 c# .net sql-server smo

我有一个 .NET 2.0 项目,当我尝试编译一些使用 SMO 的项目时出现以下错误:

The primary reference "Microsoft.SqlServer.Smo, Version=9.0.242.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91, processorArchitecture=MSIL" could not be resolved because it has an indirect dependency on the framework assembly "System.Core, Version=3.5.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" which could not be resolved in the currently targeted framework. ".NETFramework,Version=v2.0".

To resolve this problem, either remove the reference "Microsoft.SqlServer.Smo, Version=9.0.242.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91, processorArchitecture=MSIL" or retarget your application to a framework version which contains "System.Core, Version=3.5.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089".

谁能帮忙。因此,我不想将项目移动到 .NET 3.5。

谢谢

最佳答案

如异常所述,当前引用程序集需要 .NET 3.5。您必须降级支持 .NET 2.0 的 Microsoft.SqlServer.Smo。

关于c# - Microsoft.SqlServer.Smo 问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/10217422/

相关文章:

c# User.IsInRole 命名空间

c# - 使用 C#,如何确定哪个进程锁定了一个文件?

sql-server - SQL Server 触发器 - 需要更改

sql-server - SQL Server Always-on 的 Pacemaker 配置

c# - 从数据库中处理 100 万条记录的技术是什么

c# - 异步表达式C#

c# - 如何在检查器中使用带有列表的 ReorderableList 并添加新的空项目和折叠子项?

c# - 操作方法 : Validate a FileStream is a valid PDF document with . NET

.net - Delphi 和 Delphi.NET 之间的区别

c# - 如何从 401 服务器错误中获取 header