Automapper Nuget Package failed

青春壹個敷衍的年華 提交于 2019-12-10 14:21:47

问题


I tried to install http://automapper.org/ but this resulted in an error.

Install-Package : 'AutoMapper' already has a dependency defined for 'Microsoft.CSharp'. At line:1 char:1 + Install-Package AutoMapper + ~~~~~~~~~~~~~~~~~~~~~~~~~~ + CategoryInfo : NotSpecified: (:) [Install-Package], InvalidOperationException + FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PowerShell.Commands.InstallPackageCommand

Any ideas?


回答1:


Check your version of nuget package manager is current and if the version of the .net framework you are using is supported by the nuget package you are trying to install




回答2:


I was facing the same issue in VS2010 with NuGet package manager 2.8.60318.667 version. so, I have installed the older version of the Automapper 4.0.4 and its work for me.

try to install Install-Package Automapper -Version 4.0.4



来源:https://stackoverflow.com/questions/38186799/automapper-nuget-package-failed

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!