Visual Studio 2013 to 2015, MSB3884, Could not find rule set file

After loading a VS2013 C# project in VS2015 I got the dreaded MSB3884 warning (Could not find rule set file). A little annoying since I wasn’t knowingly using code analysis (but I might now).

Here’s what I did to fix the warning:

  1. On the project properties go to the Code Analysis section.
  2. Select the Browse option on the list of rule sets:
    W10_Test.png
  3. Browse to the VS2015 rule sets folder:
    C:\Program Files (x86)\Microsoft Visual Studio 14.0\Team Tools\Static Analysis Tools\Rule Sets
  4. Pick a rule set.. the default used by new projects is:
    MinimumRecommendedRules.ruleset
  5. The new rule set is applied:
    W10_Test.png

Then rebuild – problems gone !