<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://bloggingabout.net/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Search results matching tags 'c#', 'General', 'Articles', and 'Tools'</title><link>http://bloggingabout.net/search/SearchResults.aspx?a=1&amp;o=DateDescending&amp;tag=c%23,General,Articles,Tools&amp;orTags=0</link><description>Search results matching tags 'c#', 'General', 'Articles', and 'Tools'</description><dc:language>en-US</dc:language><generator>CommunityServer 2008.5 SP2 (Build: 40407.4157)</generator><item><title>Need help with Crystal Reports? Look here!</title><link>http://bloggingabout.net/blogs/jschreuder/archive/2008/07/30/need-help-with-crystal-reports-look-here.aspx</link><pubDate>Wed, 30 Jul 2008 11:36:00 GMT</pubDate><guid isPermaLink="false">813b6dfd-644e-4573-a816-eebab56ba0d0:469910</guid><dc:creator>Jan Schreuder</dc:creator><description>&lt;p&gt;Because I blog about &lt;a target="_blank" href="http://bloggingabout.net/blogs/jschreuder/archive/tags/Crystal+Reports/default.aspx"&gt;Crystal Reports&lt;/a&gt; occasionally, and created a &lt;a target="_blank" href="http://www.codeproject.com/KB/cs/CrystalHelper.aspx"&gt;helper class&lt;/a&gt; to assist in integrating it into .Net applications, I get a lot of questions from people that have problems running their reports. Especially in production environments after they deploy the reports. Unfortunately, I&amp;#39;m not a Crystal Expert. I use it in my applications but that&amp;#39;s how far it goes. I don&amp;#39;t have all the answers people might want. &lt;/p&gt;
&lt;p&gt;But I do know where you can find information about Crystal and where you do find answers to any problems you might have. I created a blog post a few weeks ago to sum up a number of resources that can help you find answers to almost all of your Crystal Reports issues. &lt;a target="_blank" href="http://bloggingabout.net/blogs/jschreuder/archive/2008/07/09/sap-is-annoying-me.aspx"&gt;Click here to read that post&lt;/a&gt;.&lt;/p&gt;</description></item><item><title>Have your C# coding style analysed by Microsoft!</title><link>http://bloggingabout.net/blogs/jschreuder/archive/2008/07/25/have-your-c-coding-style-analysed-by-microsoft.aspx</link><pubDate>Fri, 25 Jul 2008 07:58:00 GMT</pubDate><guid isPermaLink="false">813b6dfd-644e-4573-a816-eebab56ba0d0:469572</guid><dc:creator>Jan Schreuder</dc:creator><description>&lt;p&gt;Or to be more specific, by Microsoft &lt;a target="_blank" href="http://blogs.msdn.com/sourceanalysis"&gt;StyleCop&lt;/a&gt;. Now this may not be new to you, and that&amp;#39;s very likely since StyleCop was announced in May of this year, but it was new to me. &lt;/p&gt;
&lt;p&gt;The tool checks your code for coding style and more specific, the Microsoft coding style. It was developed outside the VSTS team and has absolutely no connections to &lt;a target="_blank" href="http://www.codeproject.com/KB/cs/CrystalHelper.aspx"&gt;FxCop&lt;/a&gt;. FxCop focusses on .Net Framework standards and correct use, StyleCop focuss on the way your code looks. Among others, it checks your code for the following items:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Layout of elements, statements, expressions, and query clauses &lt;/li&gt;
&lt;li&gt;Placement of curly brackets, parenthesis, square brackets, etc &lt;/li&gt;
&lt;li&gt;Spacing around keywords and operator symbols &lt;/li&gt;
&lt;li&gt;Line spacing &lt;/li&gt;
&lt;li&gt;Placement of method parameters within method declarations or method calls &lt;/li&gt;
&lt;li&gt;Standard ordering of elements within a class &lt;/li&gt;
&lt;li&gt;Formatting of documentation within element headers and file headers &lt;/li&gt;
&lt;li&gt;Naming of elements, fields and variables &lt;/li&gt;
&lt;li&gt;Use of the built-in types &lt;/li&gt;
&lt;li&gt;Use of access modifiers &lt;/li&gt;
&lt;li&gt;Allowed contents of files &lt;/li&gt;
&lt;li&gt;Debugging text&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The idea behind StyleCop, as can be read on their teamblog: &lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;em&gt;The ultimate goal of StyleCop is to allow you to produce elegant, consistent code that your team members and others who view your code will find highly readable. In order to accomplish this, StyleCop does not allow its rules to be very configurable. StyleCop takes a one-size-fits-all approach to code style, layout, and readability rules. It is highly likely that you will not agree with all of the rules and may even find some of the rules annoying at first!&lt;/em&gt;&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;I downloaded the tool (&lt;a target="_blank" href="https://code.msdn.microsoft.com/Release/ProjectReleases.aspx?ProjectName=sourceanalysis"&gt;click here&lt;/a&gt;) and installed it to test drive it on &lt;a target="_blank" href="http://www.codeproject.com/KB/cs/CrystalHelper.aspx"&gt;my CrystalHelper class&lt;/a&gt;, and boy are they right. Some of those rules are annoying. I previously checked that class with FxCop and got little to comments there. From people that used the code, I always received comments that is was readable, easy to comprehend, etc. Then again, those differences make sense. FxCop looks at usage of the .Net Framework and does so by analyzing the compiled binaries. StyleCop uses the actual code. But let me give you some examples of what StyleCop has to say about my code. &lt;/p&gt;
&lt;h3&gt;Running StyleCop&lt;/h3&gt;
&lt;p&gt;The first thing I noticed when I ran StyleCop (or Source Analysis as it&amp;#39;s called in the menu) is the enormous amount of comments. My first reaction was to remove the tool and forget about it. Actually, I had the same reaction when I first ran FxCop. I was curious enough to continue though, so let&amp;#39;s look at what the tool had to say about the following code segment.&lt;/p&gt;
&lt;div style="border-right:#cccccc 1pt solid;padding-right:1pt;border-top:#cccccc 1pt solid;padding-left:1pt;font-size:9pt;background:#f5f5f5;padding-bottom:1pt;overflow:auto;border-left:#cccccc 1pt solid;width:100%;color:black;padding-top:1pt;border-bottom:#cccccc 1pt solid;font-family:Courier New;"&gt;







&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 489&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;span style="color:#808080;"&gt;///&lt;/span&gt;&lt;span style="color:#808080;"&gt; &amp;lt;summary&amp;gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 490&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;span style="color:#808080;"&gt;///&lt;/span&gt;&lt;span style="color:#008000;"&gt; Gets or sets the data source.&lt;br /&gt;&lt;/span&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 491&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;span style="color:#808080;"&gt;///&lt;/span&gt;&lt;span style="color:#808080;"&gt; &amp;lt;/summary&amp;gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 492&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;span style="color:#808080;"&gt;///&lt;/span&gt;&lt;span style="color:#808080;"&gt; &amp;lt;value&amp;gt;&lt;/span&gt;&lt;span style="color:#008000;"&gt;The data source.&lt;/span&gt;&lt;span style="color:#808080;"&gt;&amp;lt;/value&amp;gt;&lt;/span&gt;&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 493&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#2b91af;"&gt;DataSet&lt;/span&gt; DataSource&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 494&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 495&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;span style="color:#0000ff;"&gt;get&lt;/span&gt;&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 496&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 497&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; _reportDataSource;&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 498&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 499&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;span style="color:#0000ff;"&gt;set&lt;/span&gt;&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 500&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 501&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (_reportDataSource != &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt;) &lt;span style="color:#2b91af;"&gt;&lt;/span&gt;_reportDataSource.Dispose();&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 502&lt;/span&gt;&amp;nbsp;&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 503&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; _reportDataSource = &lt;span style="color:#0000ff;"&gt;value&lt;/span&gt;;&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 504&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 505&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; } &lt;/div&gt;
&lt;p&gt;Here we have 16 lines of code which most C# developers will accept as properly styled. StyleCop however gave me remarks about almost every line of code code:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Tabs are not allowed. Uses spaces instead. On almost every line.&lt;/li&gt;
&lt;li&gt;The call to _reportData must begin with the &amp;#39;this.&amp;#39; prefix to indicate that the item is a member of the class. On lines 497, 501, 502 and 504.&lt;/li&gt;
&lt;li&gt;Statements or elements wrapped in curly brackets must be followed by a blank line. On line 498.&lt;/li&gt;
&lt;li&gt;The body of the if statement must be wrapped in opening and closing curly brackets. On line 501.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;In addition to this, it also mentioned that the fieldname should not start with an underscore. This was a remark abou the _dataSource class variable I use in this property code. For this section of code, I received a total of 23 comments!&lt;/p&gt;
&lt;h3&gt;Changing the code to satisfy the tool&lt;/h3&gt;
&lt;p&gt;As I said, most C# developers will not really have a problem with the coding style used in the above segment. But apparently, this is totally unacceptable for Microsoft developers. My next step was to change the above code so that the tool would not complain about this code. And this is what it looks like after those changes: &lt;/p&gt;
&lt;div style="border-right:#cccccc 1pt solid;padding-right:1pt;border-top:#cccccc 1pt solid;padding-left:1pt;font-size:9pt;background:#f5f5f5;padding-bottom:1pt;overflow:auto;border-left:#cccccc 1pt solid;width:100%;color:black;padding-top:1pt;border-bottom:#cccccc 1pt solid;font-family:Courier New;"&gt;







&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 489&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;span style="color:#808080;"&gt;///&lt;/span&gt;&lt;span style="color:#808080;"&gt; &amp;lt;summary&amp;gt;&lt;/span&gt;&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 490&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;span style="color:#808080;"&gt;///&lt;/span&gt;&lt;span style="color:#008000;"&gt; Gets or sets the data source.&lt;/span&gt;&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 491&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;span style="color:#808080;"&gt;///&lt;/span&gt;&lt;span style="color:#808080;"&gt; &amp;lt;/summary&amp;gt;&lt;/span&gt;&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 492&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;span style="color:#808080;"&gt;///&lt;/span&gt;&lt;span style="color:#808080;"&gt; &amp;lt;value&amp;gt;&lt;/span&gt;&lt;span style="color:#008000;"&gt;The data source.&lt;/span&gt;&lt;span style="color:#808080;"&gt;&amp;lt;/value&amp;gt;&lt;/span&gt;&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 493&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;span style="color:#0000ff;"&gt;public&lt;/span&gt; &lt;span style="color:#2b91af;"&gt;DataSet&lt;/span&gt; DataSource&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 494&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 495&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;span style="color:#0000ff;"&gt;get&lt;/span&gt;&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 496&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 497&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;span style="color:#0000ff;"&gt;return&lt;/span&gt; &lt;span style="color:#0000ff;"&gt;this&lt;/span&gt;.ReportDataSource;&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 498&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 499&lt;/span&gt;&amp;nbsp;&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 500&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;span style="color:#0000ff;"&gt;set&lt;/span&gt;&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 501&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 502&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;span style="color:#0000ff;"&gt;if&lt;/span&gt; (&lt;span style="color:#0000ff;"&gt;this&lt;/span&gt;.ReportDataSource != &lt;span style="color:#0000ff;"&gt;null&lt;/span&gt;)&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 503&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 504&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;span style="color:#0000ff;"&gt;this&lt;/span&gt;.ReportDataSource.Dispose();&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 505&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 506&lt;/span&gt;&amp;nbsp;&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 507&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;span style="color:#0000ff;"&gt;this&lt;/span&gt;.ReportDataSource = &lt;span style="color:#0000ff;"&gt;value&lt;/span&gt;;&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 508&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&amp;nbsp;&lt;br /&gt;&lt;span style="color:#2b91af;"&gt;&amp;nbsp; 509&lt;/span&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; } &lt;/div&gt;
&lt;p&gt;All tabs are now replaced with spaces. The body if the if statement is now enclosed in brackets. There&amp;#39;s an empty line after the closing brackets for the get body and the if body. All class members are now preceded by &amp;#39;this.&amp;#39;. And yes, I removed the underscore from the class member. Not that much different, but some of the changes make sense, I guess.&lt;/p&gt;
&lt;h3&gt;Other comments found by the tool&lt;/h3&gt;
&lt;p&gt;The tool does find other things as well. Here&amp;#39;s a short list of some other comments the tool made about my CrystalHelper class:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Invalid spacing around the comma. All comma&amp;#39;s should be followed by a single space&lt;/li&gt;
&lt;li&gt;Invalid spacing around the opening parenthesis. There should not be a single space after an opening parenthesis&lt;/li&gt;
&lt;li&gt;Invalid spacing around the closing parenthesis. There should not be a single space before a closing parenthesis&lt;/li&gt;
&lt;li&gt;The spacing around the symbol &amp;#39;=&amp;#39; is invalid. You need to add a single space before and after the &amp;#39;=&amp;#39;symbol&lt;/li&gt;
&lt;li&gt;All using directives must be placed inside of the namespace&lt;/li&gt;
&lt;li&gt;All methods must be placed after all constructors&lt;/li&gt;
&lt;li&gt;All methods must be placed after all properties&lt;/li&gt;
&lt;li&gt;All private methods must be placed after all protected methods&lt;/li&gt;
&lt;li&gt;All private methods must be placed after all public methods&lt;/li&gt;
&lt;li&gt;All protected constructors must be placed after all public constructors&lt;/li&gt;
&lt;li&gt;The method must have a documentation header&lt;/li&gt;
&lt;li&gt;The summary section in the documentation header must not be empty&lt;/li&gt;
&lt;/ul&gt;
&lt;h3&gt;Should you use it?&lt;/h3&gt;
&lt;p&gt;A difficult question. My first reaction, as I said before, was to remove the tool and forget about it. But that was the same reaction I had when I first started using FxCop. And yet, that is now a tool I use on a daily basis. &lt;/p&gt;
&lt;p&gt;I also have a problem with non-enforceable coding standards. Put 10 developers in a room to talk about coding standards and you end up with either 10 slightly different versions, or one that none of them will adhere to. My experience over the last 20 years is that, if you can&amp;#39;t enforce coding standards, you can forget about introducing them and hope that it will all go well.&lt;/p&gt;
&lt;p&gt;And that&amp;#39;s exactly where this tool comes in. You can now enforce a number of rules to make code more readable and understandable. You might want to disagree to some of them (I don&amp;#39;t agree to using spaces instead of tabs) but you can run the tool and check if your coding style matches that of the tool. And when all developers in your team use the tool and change their code accordingly, then all your code looks quite similar. Making it easier for your teammembers to work on code by other developers. And that&amp;#39;s the main objective for any development team to create a coding standard. &lt;/p&gt;
&lt;p&gt;The tool can also be included in MS-Build scripts, so you can easily make sure the build is broken when a developer ignores the coding standard. &lt;strong&gt;So yes, use it!&lt;/strong&gt;&lt;/p&gt;
&lt;h3&gt;Some tips when using StyleCop&lt;/h3&gt;
&lt;p&gt;Once you have installed the tool and are ready to check your code using the tool, you might want to consider doing the following first:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Go to the C# section in Tools -&amp;gt; Options -&amp;gt; TextEditor and change the properties for the tabs so that it inserts spaces and click the OK button&lt;/li&gt;
&lt;li&gt;Open the class file and select all code using CTRL-A&lt;/li&gt;
&lt;li&gt;Now hold the CTRL key and press K, followed by F. This automatically re-aligns the entire class and replaces any tabs in your code with spaces. Do this for all class files in your project.&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;When you do this, the following will happen in your code.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Tabs are converted into spaces&lt;/li&gt;
&lt;li&gt;Spacing before and after open and closing parenthesis is adjusted&lt;/li&gt;
&lt;li&gt;Spacing around symbols is adjusted&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;StyleCop will not give yo any comments about those items. Which leaves the more interesting items to fix.&lt;/p&gt;
&lt;h3&gt;What&amp;#39;s next for StyleCop?&lt;/h3&gt;
&lt;p&gt;Like all Microsoft tools, this is a work in progress. New features and options will be added and bugs will be fixed. But for the near future, the following has already been announced:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;The tool is still called Source Analysis when you look for it in the Tools menu. It will be renamed to StyleCop&lt;/li&gt;
&lt;li&gt;A small SDK will be made available to allow you to extend the tool with your own rules&lt;/li&gt;
&lt;li&gt;Documentation about the currently available rules (which in fact opens up the Microsoft C# coding standards to the community)&lt;/li&gt;
&lt;li&gt;Automatically change your code to enforce some of the rules&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;So keep an eye on the &lt;a target="_blank" href="http://blogs.msdn.com/sourceanalysis/"&gt;StyleCop blog&lt;/a&gt; for future releases of this tool. I will be discussing the tool with my team as soon as possible and start using it. Finally a way to have our code look similar!&lt;/p&gt;</description></item></channel></rss>