C#“Multiple assemblies with equivalent identity have been imported”错误

背景:解决方案中已有4个.net4的项目
在整合项目到解决方案时,突然报Multiple assemblies with equivalent identity have been imported错误,说packages.NET 4.5中的DLL冲突

CS1703 Multiple assemblies with equivalent identity have been imported: 'C:\Users\Administrator\Documents\Visual Studio 2015\Projects\DakaPathAppSolution\packages\Microsoft.Bcl.1.1.8\lib\net40\System.Threading.Tasks.dll' and 'C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5.2\Facades\System.Threading.Tasks.dll'. Remove one of the duplicate references.

解决方法一:
NuGet中卸载冲突的包
C#“Multiple assemblies with equivalent identity have been imported”错误_第1张图片
解决方法二:
如果冲突的包中包含必须要使用的方法或类,可以在解决方法一后,然后重新安装,也可以解决冲突问题

你可能感兴趣的:(C#)