Is there a way to show ALL the compiler warnings i

2019-02-16 08:45发布

问题:

I'm cleaning up a project to get rid of all the warnings, but I can only see the first 100 or so in the Error List pane.

This is a problem because we're using Team Server for source control and all the warnings shown are in files that are currently checked out (and therefore I can't modify without making someone else possibly do a lot of work when they check in).

I'd like to be able to see the full list so I can continue my cleaning while others are working.


In case it makes a difference,

  • The project in question is a VB.NET web application (using the application model). It doesn't seem that I can compile individual pages.
  • Environment is VS2010 Premium; I can get Ultimate on my machine if necessary.

回答1:

The full list of warnings should be visible in the output window. After building open the output window, switch it to the build output and you should have access to all errors emitted by the compiler.

Note: The compiler itself still has a hard limit on the number of errors it will report for a given project (true for both VB and C#). This cannot be overridden in Visual Studio or the command line.



回答2:

Can't you temporarily locally do something similar to

#pragma warning disable 

in the files which are checked out by the others so you don't have to see their warnings?