Tuesday, June 9, 2009

C# Code Reviews using StyleCOP

Installing and Download StyleCop

StyleCop analyzes C# code with a set of rules to check whether the code follows the rules. You can download StyleCop from this link. If you click on the downloads section, you will see three setups, one is the StyleCop setup which actually installs the software and the other two are CHM help files. One help file talks about the rules and the other about the API exposed by StyleCop.

Once you install StyleCop, nothing will be seen as in start menu. When you open any project of C# and right click on the project, you should see two menus in the project as shown in the figure below - one which helps us select the rules, i.e. the Stylecop settings menu and the other which runs these rules on the C# Project.

see full detail: http://www.c-sharpcorner.com/UploadFile/shivprasadk/StyleCOP03302009022805AM/StyleCOP.aspx