C# - Xamarin : installing android.support.design package - visual-studio

i'm trying to install "Install-Package Xamarin.Android.Support.Design" into Xamarin Visual Studio 2015, but after it starts downloading, this error occurs
Install-Package : Unable to find package 'Xamarin.Android.Support.Design'
At line:1 char:1
+ Install-Package Xamarin.Android.Support.Design
+ CategoryInfo : NotSpecified: (:) [Install-Package], Exception
+ FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
i don't understand any of that, what is wrong?

Ensure that you have a proper NuGet source defined. You can go to Tools -> Options -> NuGet Package Manager -> Package Sources to make sure. i.e.: https://api.nuget.org/v3/index.json
Secondly you should double check that your NuGet version is the latest. Go to Tools -> Extensions and Updates and update if you aren't on the latest version.
Finally you could also try to manually download the package from https://www.nuget.org/packages/Xamarin.Android.Support.Design/ and setup a local NuGet repository to ensure that works. Chances are one of the first bullets should fix this.
Source: https://github.com/NuGet/Home/issues/842

Related

naxam mapbox for xamarin.forms nuget package doesn't work

a freshly started xamarin.forms usuall error for no reasons solved by deleting bin and obj folders and rebuilding solution now everything should be perfect ... i type this in package manager :
Install-Package Naxam.Mapbox.Forms -Version 1.0.5.2
and it gives me this error :
Install-Package : NU1107: Version conflict detected for Xamarin.Android.Support.Fragment. Reference the package
directly from the project to resolve this issue.
formsMAPapp.Android -> Naxam.Mapbox.Forms 1.0.5.2 -> Naxam.Mapbox.Droid 6.4.0.1 ->
Xamarin.Android.Support.Fragment (>= 27.0.2.1)
formsMAPapp.Android -> Xamarin.Android.Support.Design 25.4.0.2 -> Xamarin.Android.Support.Fragment (=
25.4.0.2).
At line:1 char:1
+ Install-Package Naxam.Mapbox.Forms -Version 1.0.5.2
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Install-Package], Exception
+ FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
so after a whole day of batteling with the versions of xamarin components and trying to update each one of them i needed to update Xamarin.Android.Support.Fragment wich depended on a higher version of if i remember correctly Xamarin.Android.Support wich depended also on a higher version of other components none of them i could update so i figured i just have to update visual studio xDD pretty easy ... then what i did is installed each one of mapbox dependency from the nuget package manager

No option for adding online packages in VS 2017 Community

I am trying to install a few online or external packages into my project using nuget in Visual Studio 2017. I tried the package console and it fails. The problem seems to be that the only package source I have available as an option is "Microsoft Visual Studio Offline". There is no "All" option in the package source drop down at the top of the package console, which I believe I need to see if I am trying to add online packages. I have searched all over the place for what might be a simple answer, but all answers seem to deal with other related matters and not specifically this one. Maybe I didn't type the correct phrase to yield results, but I tried and couldn't find them. What am I missing? A setting? Not the correct license? Thanks.
PM> install-package jquery
install-package : Unable to find package 'jquery'
At line:1 char:1
+ install-package jquery
+ ~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Install-Package], Exception
+ FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
Go to manage NuGet package manager, click to setting gear button.
Then add new package source:
Name: nuget.org
URL: https://api.nuget.org/v3/index.json

Nuget Install A Package

I am trying to install "Microsoft.ProjectOxford.SpeechRecognition-x64" using Nuget on Visual studio. I got the following error. What does it mean? Thanks
PM> Install-Package Microsoft.ProjectOxford.SpeechRecognition-x64
Install-Package : Solution is not saved. Please save your solution before managing NuGet packages. At line:1 char:1
+ Install-Package Microsoft.ProjectOxford.SpeechRecognition-x64
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (:) [Install-Package], InvalidOperationException
+ FullyQualifiedErrorId : NuGetUnsavedSolution,NuGet.PackageManagement.PowerShellCmdlets.InstallPackageCommand
The NuGet team deprecated solution level packages in NuGet 3.0. So install the NuGet package to solution without any project is not supported. You need create a project, then add the package to the project.

Trying to install Microsoft.AspNet.WebPages.WebData from Nuget

I have migrated my project into Visual Studio 2013 from 2010. I am trying to install Microsoft.AspNet.WebPages.WebData to fix some erors I am getting. When I try install from the Nuget console I get this error:
Install-Package : Could not install package
'Microsoft.AspNet.WebPages.WebData 3.2.2'. You are trying to install
this package into a project that targets '.NETFramework,Version=v4.0',
but the package does not contain any assembly references or content
files that are compatible with that framework. For more information,
contact the package author.
At line:1 char:16
+ Install-Package <<<< Microsoft.AspNet.WebPages.WebData
+ CategoryInfo : NotSpecified: (:) [Install-Package], InvalidOperationException
+ FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PowerShell.Commands.InstallPackageCommand
Anyone know how I can fix this?

Failed to add reference to 'Newtonsoft.Json'

I just installed Windows 8 on my PC and downloaded Microsoft Visual Studio Express 2012 for Windows 8. Updated and everything, and when I try to install anything thru Package Manager Console, I get following error:
PM> Install-Package Parse
Attempting to resolve dependency 'Newtonsoft.Json (≥ 4.5.9)'.
Successfully installed 'Newtonsoft.Json 4.5.11'.
Successfully installed 'parse 1.0.5'.
Successfully uninstalled 'Newtonsoft.Json 4.5.11'.
Install failed. Rolling back...
Install-Package : Failed to add reference to 'Newtonsoft.Json'.
At line:1 char:1
+ Install-Package Parse
+ ~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Install-Package], InvalidOperationException
+ FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PowerShell.Commands.InstallPackageCommand
Does anyone know how to fix this error?
Thanks, Jack
Check if you already have Newtonsoft.Json reference added in packages.config. If yes, delete Newtonsoft.Json entry and retry Install-Package.
Sometimes just removing it from packages.config might not be enough. I had to remove the Newtonsoft.Json directory from the packages-directory, after that installing worked.

Resources