I tried to install Microsoft.Net.Http in a Xamarin.Forms project when I ran into this problem. Here is what you should try to get rid of this error:
1- Update Xamarin.Forms to the latest version in each solution project.
2- My main goal was to install Microsoft.Net.Http , and this package had dependencies on Microsoft.BCL and Microsoft.BCL.Build . I tried installing these packages (Microsoft.Bcl and Microsoft.Bcl.Build) individually and it worked for me. First install the latest version of Microsoft.Bcl.Build 1.0.21 ( If version 1.0.14 is not installed, try the latest version). Then install Microsoft.Bcl , which should be successfully installed, and this solution worked for me, and I hope this works for you too. After installing these packages, I was able to install Microsoft.Net.Http .
NOTE. When installing packages ( Microsoft.Bcl and Microsoft.Bcl.Build ) in your projects, check which version you are installing. Try installing a different version if it doesn’t work, and let me know. If the problem is not resolved.
Excellent day:)
Ali Raza
source share