How to update my Nuget package manager in VISUAL STUDIO 2012 - asp.net

Visual studio shows no update button to update the Nuget package manager, but when i try to install Microsoft.EntityFrameworkCore.SqlServer i'm getting a error saying update the nuget manager by going to particular website (https://www.nuget.org/downloads)

Upgradation of VS12 nuget package manager is not possible now!
If you want any packages that is compatible with VS2012, while installing any packages you check with versions of that particular package version in nuget official website (supported for VS12) by clicking on the version tab.

You already have the most recent version of NuGet that is available for Visual Studio 2012. VS2012 is very old (in software terms) and hasn't has feature upgrades in a long time. You'll need to upgrade to a newer version of Visual Studio for some NuGet features to work (for example, to be compatible with packages that use features only available in newer versions of NuGet). Alternatively, you might have luck with Entity Framework 6, rather than Entity Framework Core. However, there's a chance that even then you'll need to install an older version of EF6, rather than the newest version, to find a version that is compatible with VS2012.

Related

Using SQLite with Xamarin.Forms cross-platform project

I have used Visual Studio 2017 Community edition to create a plain vanilla cross platform PCL project, and would like to use SQLite. The only thing done to the project(s) was the use of Nuget to update all packages that needed updating.
Then, following the instructions on the Xamarin website at
https://developer.xamarin.com/guides/xamarin-forms/application-fundamentals/databases/
I used Nuget to install sqlite-net-pcl,
It all seemed to work OK, except at the end the following error appears.
I presume the documentation is slightly dated. Should I change the target .NET framework. If so, to what?
As of v1.3 SQLite-Net-PCL is actually no longer a PCL, it is a .Net standard library.
You need to install version 1.2.0 of the NuGet package to use it inside a PCL - from the nuget package manager you can select a version so install v1.2.0 into all your projects.
The library above worked OK as a PCL library, but what I disliked was that the platforms were split out in to separate DLLs so you had a different dependency for each platform.
This library is for .NET Standard and only has a single DLL for all platforms:
https://github.com/MelbourneDeveloper/SQLite.Net.Standard
It does not support the ORM like functionality in the above library though.

Visual Studio for Mac and Xamarin Forms PCL - can't install NodaTime 2.0 with NuGet

I'd like to use NodaTime with Xamarin Forms in a PCL, however the NuGet install fails with this message:
Could not install package 'NodaTime 2.0.0'. You are trying to install this package into a project that targets '.NETPortable,Version=v4.5,Profile=Profile259',
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.
The NuGet package information says it doesn't have any dependencies, what's up?
NodaTime 2.0.0 only supports .NET45 or .NET Standard. You either need to update your Xamarin Forms project to .NET Standard, or downgrade your NodaTime version 1.3.4.

How to find out if a nuget Package is usable in .NET Core

If i search a nuget package within visual studio or at https://www.nuget.org/, how do i see if the nuget package is usable in .net core?
As far as I know, there is currently no possibility to search directly for nuget packages which can be used in .net core (Source). But can i check it for a specific one?
Currently there is no way to search for packages by target-framework.
You can follow this issue on Github for news/more information

How to downgrade a Visual Studio extension?

I need to downgrade NuGet Package Manager extension for Visual Studio 2015 for testing purpose. How to do this? Is there any way to download an older version of this extension and install it into Visual Studio?
This site lists all recent releases, you must install the VSIX file.
https://github.com/NuGet/Home/releases
You can usually try a variation of the link you can get from the download button from the extension's page on https://marketplace.visualstudio.com/ .
For example, at the time of this writing Failwyn/WebCompiler64 version 1.14.9.2 has an issue, so I downloaded version 1.14.8 from https://marketplace.visualstudio.com/_apis/public/gallery/publishers/Failwyn/vsextensions/WebCompiler64/1.14.8/vspackage .
An easier way to downgrade any visual studio code extension is by:
1. search for the extension in visual studio code
2. Right click on the extension you want to downgrade
3. select Install Another Version...
4. Pick the version from the list if any and install
VS Code - how to rollback extension/install specific extension version

How to Install MVVMLight in Xamarin Studio Xamarin.Forms PCL

I think this is related to this -
Cannot install MvvmLight for Windows Phone 8.1 app project
Trying to install libs only nuget. Seen a PCL version mentioned somewhere but its not in the Nuget list.
Could not install package 'MvvmLightLibs 4.4.32.1'. You are trying to
install this package into a project that targets
'portable-net45+win+MonoAndroid10+MonoTouch10', 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.
When I try to install in Xamarin Studio.
Can I assume that I need the latest version of NuGet and the version 2.8.1 is not new enough in XS?
Does MVVMLight support Xamarin Studio? Does anyone know a workaround, I am currently on Indie license and would love to progress with this on a Forms based prototype.
Looking at the MvvmLightLibs 4.4.32.1 NuGet package it does not have any Portable Class Libraries (PCLs) so you will not be able to install it into a PCL project.
Take a look at the Portable.MvvmLightLibs NuGet package instead. That package has a PCL assembly and you should be able to install it into the Xamarin.Forms PCL project.

Resources