I know there is another question with exact the same problem, but I went trough all those answers, and none helped me. :( (This was the question.)
I just created a new A
What worked for me:
Package Manager Console (Visual Studio 2019 Comunity):
Install-Package NuGet.CommandLine
nuget locals all -clear
Rebuild solution.
In my case, I had to open the .csproj file and add the reference by hand, like this (Microsoft.Extensions.Identity.Stores.dll was missing):
<Reference Include="Microsoft.Extensions.Identity.Stores">
<HintPath>..\..\..\..\Program Files\dotnet\sdk\NuGetFallbackFolder\microsoft.extensions.identity.stores\2.0.1\lib\netstandard2.0\Microsoft.Extensions.Identity.Stores.dll</HintPath>
</Reference>
Double check the name of your project folder. In my case my project folder was named with spaces in it. When I cloned the project from Team Foundation Server using git bash the spaces in the folder name were converted to: "%20". Changing those back to spaces fixed the problem for me.
I had the same problem, even with no other errors showing on the "Error List" view after "Rebuild Solution". However, on the "Output" view, I saw the error that was behind the issue:
The primary reference "C:...\myproj.dll" could not be resolved because it was built against the ".NETFramework,Version=v4.6.1" framework. This is a higher version than the currently targeted framework ".NETFramework,Version=v4.5"
Once I corrected this, the issue was resolved.
Check all the projects are loaded. In my case one of the project was unloaded and reloading the project clears the errors.
I have the same problem, the problem was that solution path have spaces in the name and vs for some reason not resolve the package... download my repository again just renaming the solution with out spaces in the name.
e.g:
/Repo/Project Name/src
should be
/Repo/ProjectName/src