'Is there a way to clear the Error List window of custom errors?

I use several custom tools during the build process, mostly code generators for service references, T4 templating, and the like.

When these produce errors or warnings, they show up in the Error List window as expected. However, if I do a build, rebuild, or clean of some portion of the solution that does not touch upon the errors produced previously (say I'm not building a project that has a service reference import failure), the old list is still displayed.

Is there a way to fix that: Tool, plugin, build action, anything? I don't want to ignore the errors/warnings, only want the relevant ones to show based on what I'm doing. If not I guess this would be a request for the VS team.



Solution 1:[1]

Closing and re-opening the project is the only way to clear the list. From what I can tell and the research I've done, the error/warnings window is like a session log for the project. Once you close the project the log is deleted.

Solution 2:[2]

Cleaning the solution does it as well. Clear the error list in Visual Studio

Solution 3:[3]

You can also unload and reload the project also. That's what works for me.

Solution 4:[4]

On the error list window in VS2015 there's a drop down that defaults to Build + IntelliSense switching this to Build Only fixed my issues (opening dlls via resharper and VS going crazy over it)

Solution 5:[5]

I'm in VS 2013, writing reports. I tried all the above steps (Clean Solution/Close solution/Reopen Solution). Still had 3 errors in there 2 of which were from a 2 other reports that were not even opened. The steps above didn't work.

What I had to do was redo those steps AND close VS 2013 & reopen it. THAT fixed it. One would think by simply closing/reopening the solution, it would fix it. But restarting VS was the only way to fix it for me.

Solution 6:[6]

If you work with multiple projects in one solution in VS2012, a filter by current project works well. You select your project in solution explorer and you get the list with the errors that belong to the selected project only.

enter image description here

Solution 7:[7]

I had this issue with speechlib and I had to go back into the assembly and un-check "Microsoft Speech Object Library," and re-check it to clear 59 errors when I ran my Debug again. This method proved successful. I closed out Visual Studios and restarted it & that didn't work, nor did "clean solution." To answer your question, would depend on the situation however. As far as assemblies go, just remove them and then re-add them.

Solution 8:[8]

An old thread - VS 2022 refreshes the error list on Rebuild All.

Solution 9:[9]

I have VS 17, with a Python project. With Python, there is no Build or Clean. Closing the solution leaves the unwanted stuff in the ErrorList window, and reopening it doesn't change it. I get my errors from running MyPy. The unwanted stuff has the Project field blank, which I guess is why it isn't affected by new content associated with my project. What I had to do to clear it was exit Visual Studio altogether and relaunch it.

Solution 10:[10]

I'm running Vs2022 64 bit Version 17.1.4. My current project is a Winforms app and had an error that was pointing to a line that no longer existed! No rebuild, clean would work, only unloading/reloading or restart visual studio fixed it.