我想下載,在我的Windows Phone項目解析JSON,所以我決定通過的NuGet在視覺工作室下載newtonsoft.json
庫,但我收到如下:無法安裝:Newtonsoft.Json
PM> Install-Package Newtonsoft.Json
Successfully installed 'Newtonsoft.Json 6.0.1'.
Successfully uninstalled 'Newtonsoft.Json 6.0.1'.
Install failed. Rolling back...
Install-Package : Could not install package 'Newtonsoft.Json 6.0.1'. You are trying to install this package into a project that targets 'WindowsPhone,Version=v8.0', but the package does not
contain any assembly references that are compatible with that framework. For more information, contact the package author.
At line:1 char:1
+ Install-Package Newtonsoft.Json
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Install-Package], InvalidOperationException
+ FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PowerShell.Commands.InstallPackageCommand
嘗試更新的NuGet到最新版本並重新啓動Visual Studio中我的答案。 –
@BenjaminGruenbaum已經測試過,但沒有變化! – user2068754
@ user2068754你是如何測試它的?使用您嘗試的相關代碼示例更新您的問題。告訴我們它是如何工作的。 – Dayan