简体   繁体   English

无法从Nuget安装Package System.Net.Http

[英]Can't Install Package System.Net.Http from Nuget

I cannot install the package System.Net.Http I tried updating my Nuget but still same error occur by the way i'm using Visual Studio 2015 Community developing my android application 我无法安装包System.Net.Http我尝试更新我的Nuget但仍然发生同样的错误我正在使用Visual Studio 2015 Community开发我的Android应用程序

This is the error: 这是错误:

Could not install package 'System.Net.Http 4.0.0'. 无法安装包'System.Net.Http 4.0.0'。 You are trying to install this package into a project that targets 'MonoAndroid,Version=v6.0', but the package does not contain any assembly references or content files that are compatible with that framework. 您正在尝试将此软件包安装到以“MonoAndroid,Version = v6.0”为目标的项目中,但该软件包不包含任何与该框架兼容的程序集引用或内容文件。 For more information, contact the package author. 有关更多信息,请与软件包作者联系。

Please help me. 请帮我。 Thanks :) 谢谢 :)

Currently you are not going to be able to use System.Net.Http 4.0.0 even if you managed to install it into a Xamarin Android project since Xamarin does not fully support the new .NET Core NuGet packages, such as System.Net.Http. 目前,即使您设法将其安装到Xamarin Android项目中,您也无法使用System.Net.Http 4.0.0,因为Xamarin不完全支持新的.NET Core NuGet软件包,例如System.Net。断点续传。 So you should look at using another NuGet package. 所以你应该看看使用另一个NuGet包。

You could try the Microsoft.Net.Http NuGet package instead which includes assemblies for Xamarin Android projects. 您可以尝试使用Microsoft.Net.Http NuGet包,其中包含Xamarin Android项目的程序集。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM