Failure to reference a nuget package

Asked

Viewed 5,745 times

0

After installing the W10 Anniversary Update, I’ve been trying to build an open source project that I normally did before and now can’t. I get the following error in the output of Visual Studio 2015 Update 3:

Severity    Code    Description Project File    Line    Suppression State
Error   CS0246  The type or namespace name 'GeoExtensions' could not be found (are you missing a using directive or an assembly reference?)

The error is not with the project, obviously, since there are hundreds of people compiling it without problem.

I’ve tried to:

  • Clean Solution
  • Bebuild Solution
  • Check with the nuget to make sure the package is right
  • "restore" all nuget packages
  • Uninstallation and installation of all packages.
  • Format your computer and perform the cleanest possible installation of Visual Studio
  • And any other "solution" I found in stackoverflow or any other site, in several days of search

But the problem remains.

  • In the file Packages.config, you will see all the Packages that Nuget has installed... Delete the part related to Geoextensions, and try to install again via Nuget. I believe it may be a problem related to the package directory or even reference

  • @Forlani does not solve it. The first thing I tried was to uninstall and install the package. // I did a test and realized that installing Geoextensions in another project works perfectly.

  • Try referencing the Dll explicitly (Project)->References->Add Reference.

1 answer

2

This has happened to me, follow the steps that usually solves my problem.

  1. Make a "Clean Solution"
  2. Close the Visual Studio
  3. Via Windows Explorer, go to the folder of your solution
  4. Delete the folder packages
  5. Open your solution in Visual Studio again
  6. Do a "Rebuild"
  • It doesn’t. I just gave up and made a "helper" to replace the package.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.