Welcome to MSDN Blogs Sign in | Join | Help

Browse by Tags

All Tags » FAQ » FxCop   (RSS)

FAQ: How do I prevent FxCop 1.36 from firing warnings against generated code?

I've upgraded from FxCop 1.35 to 1.36 and now FxCop has started to fire warnings against typed DataSets and other generated code. How do I turn this off? The reason this is occurring is because we changed the way that FxCop analyzed generated code. Whereas
Posted by David M. Kean | 6 Comments
Filed under: , ,

FAQ: Which Code Analysis rules shipped in which version?

In response to a lot of recent requests, we've put together a complete list of rules that shipped in the different versions of Visual Studio Code Analysis and FxCop. Attached is an Excel worksheet providing this information for Visual Studio 2005, Visual

FAQ: How do I debug a custom rule?

While writing your custom rule, you will likely come across a need to debug it and work out why it's behaving in a particular manner. Debugging within FxCop Debugging a custom rule within the FxCop UI is actually quite easy. To do so, simply: Open the

FAQ: Why is file and line information available for some warnings in FxCop but not for others?

It appears that sometimes FxCop displays a link to the source line and file in the Message Details window and sometimes it doesn't. Why this inconsistent behavior? There are three usual reasons why this occurs: Source lookup is disabled. To turn source

FAQ: How do I get the SourceContext for a local?

I want to fire on the naming of a local, however, whenever I pass the local to the Problem constructor, the source information for the method is always used. How do I get FxCop/Code Analysis to use the source information for the local instead? Because

FAQ: How do I run FxCop during a post-build event?

A little known feature of FxCop (in particular FxCopCmd.exe) is its ability to be integrated into the build process within Visual Studio. Although not a replacement for the Code Analysis functionality available within both Visual Studio Team Edition for
Posted by David M. Kean | 3 Comments
Attachment(s): VSConsoleOutput.xsl

FAQ: Why is FxCop 1.32 not available for download? [David Kean]

Update: While SharePoint Portal Server 2003 will not run side-by-side with .NET 2.0, SharePoint Portal Server 2003 SP2 will. For more information, see: http://support.microsoft.com/kb/907763 . We have had a lot of users contacting us since we released

FAQ: Can I create custom rules that target both Visual Studio and FxCop? [David Kean]

I have users using both Visual Studio and FxCop, and I want to create custom rules that run on both. Is this possible? Although in the future we do plan on making it easier to move custom rules between Visual Studio and FxCop, currently you must recompile

FAQ: Why does FxCop ignore my in-code (SuppressMessageAttribute) suppressions? [David Kean]

FxCop 1.35 brings with it the ability to suppress messages in code via the use of the SuppressMessage attribute. This allows you to do the following: public class PublicKey { private byte [] _Token; [...] [SuppressMessage( "Microsoft.Performance" , "CA1819:PropertiesShouldNotReturnArrays"
 
Page view tracker