5

I'm in the process of updating a library in a larger solution. For this purpose, I have removed the old references in all projects and added new ones.

If I compile the solution now I get about 3000 build errors, which indicate that various classes are defined in the old, removed libraries and I should add a reference to them.

After I have opened a reported file, Visual Studio recognizes that these classes are also included in the new libraries and removes the error.

Now I don't want to open hundreds of files to make these ghost errors disappear, especially because the problem repeats itself after the next build.

Does anyone have any idea how I can get Visual Studio to stop reporting ghost bugs?

I'm using Visual Studio 2022.

6
  • C#? VB.NET? C++? TypeScript? Keep in mind no other here can see your screen, so edit the question to include enough details (or screen shots if it is difficult to describe clearly). Commented Sep 14, 2022 at 15:46
  • Sorry, its a solution with C# Projecta. But it seems to me to be more an VS issue than a language problem. Commented Sep 15, 2022 at 6:23
  • 4
    Clean the solution, remove bin and obj directories, restart Visual Studio, remove the .vs directory? Commented Sep 15, 2022 at 15:10
  • Try to close Visual Studio and delete .vs folder in project location, it should work. Take a look at this answer, stackoverflow.com/a/57519860/3559462 Commented Sep 15, 2022 at 15:15
  • 1
    While you might feel like it is a VS issue, different languages use different technologies behind the scene to enable code analysis and error reporting. By knowing you are working on C# projects, I can then add two more tags and experts in those areas can take a look. Make sure you select the correct tags for your future questions here. Commented Sep 15, 2022 at 15:22

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.