Reputation: 175
Using Visual Studio Community 2017 for Mac
I downloaded this version to open an 1+ year old project, and when I try to build and run, I get this error:
Any tips on what to do here? Have tried google'ing, but with no luck.
Upvotes: 0
Views: 6152
Reputation: 19
for vs 2019 windows: 1.unload project 2.load project 3.try uninstall package form nuget manager then automatically fix all but u need
Upvotes: 0
Reputation: 47937
The error message is:
TypeLoadException: Could not resolve type with token 01000063 from typeref (expected class 'NuGet.Packaging.Core.PackageDependency' in assembly 'NuGet.Packaging, Version=5.3.0.4, Culture=neutral, PublicKeyToken=31bf3856ad364e35')
Also it looks like you have .NET Core SDK 3.0 installed.
The problem is that your MSBuild version (that is shipped with Mono) is incompatible with the .NET Core SDK you have installed. NuGet had some breaking changes which means that a particular Mono version can only support a particular set of .NET Core SDKs.
Your options are:
Currently only the Visual Studio for Mac version 8 dependencies on the .NET Core SDK versions are listed.
For Visual Studio for Mac 2017 (version 7.x) you would likely need .NET Core 2.1.5xx or older.
Upvotes: 1