Reputation: 2972
Opened an old project from years ago. Build fails because Visual Studio (2019) does not recognize an assembly that is clearly there - specifically, Autofac.
You can see it in project references (not marked as missing)
You can see it in the Object Browser, listing all the types referenced in the code
What is going on here? Intellisense doesn't even pick up types (Tried cleaning, rebuilding, re-importing packages)
Upvotes: 1
Views: 1464
Reputation: 2972
Okay, this is what worked. I had to remove the reference to the Autofac dll, and then add it back. Note - I added it back from the same exact location, the same exact version. But after this, Visual Studio 'magically' recognized it. If you come across a similar problem, and nothing else works, give it a try. I don't know the reason, I can only assume this is some sort of a bug in Visual Studio.
Upvotes: 1