User281315223 posted
Sadly, you'll likely need to use a third-party or extension to Visual Studio to handle this, but don't worry it certainly can be done.
Using Resharper
Resharper is an incredible development tool that offers a free 30-day trial that you could use and it does a heck of alot more than just detect dead code. It provides its own Intellisense, offers improvements over existing code and helps you write cleaner
and more maintainable code.
Within Resharper, there is an option called "Analyze Errors in Solution" option within Resharper, which can be enabled through the Resharper status bar (right-click on the Resharper icon).
After that is enabled, right-click on your project or solution and select "Find Code Issues". You should see a "Unused Symbols" tab within the results that will contain unused classes, methods and members. (It should say "Type or Member is never used")
Using
FxCop
You can also use Microsoft's FxCop tool to perform code analysis and find "dead code" within your applications. You can find a post here that
details installing it if you aren't using at least Visual Studio 2010 Premium or Ultimate (It is integrated in newer versions of Visual Studio under the Code Analysis option.)
Using NDepend
NDepend is another tool that can help suggest and find unused methods as well as optimize some of your existing code that you might want to consider trying as well.
Related Suggestions and Discussions