title: Installing Custom StyleCop Rule
body: <p>In starting to create a custom StyleCop rule I have followed the instructions on the <a href="https://github.com/Visual-Stylecop/Visual-StyleCop/wiki/Writing-Custom-Rules-for-StyleCop" rel="nofollow noreferrer">Visual StyleCop Github</a>.</p>
  
  <p>• I've created a class, <code>MyStyleCopRules.cs</code>:</p>
  
  <pre><code>[SourceAnalyzer(typeof(CsParser))]
  public class MyStyleCopRules : SourceAnalyzer
  {
      public override void AnalyzeDocument(CodeDocument document)
      {
         ...
  </code></pre>
  
  <p>• Added an XML document, with the build action set to <strong>EmbeddedResource</strong>, called <code>MyStyleCopRules.xml</code>:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8" ?&gt;
  &lt;SourceAnalyzer Name="My StyleCop Rules"&gt;
      &lt;Rules&gt;
        &lt;Rule Name="Fully Qualified Using Statements" CheckId="IS0001"&gt;
          &lt;Context&gt;Using statements must be fully qualifed.&lt;/Context&gt;
          &lt;Description&gt;Fires when using statements are not fully qualifed.&lt;/Description&gt;
        &lt;/Rule&gt;
      &lt;/Rules&gt;
  &lt;/SourceAnalyzer&gt;
  </code></pre>
  
  <p><strong>Other possibly pertinent facts:</strong></p>
  
  <ul>
  <li><p>This library is building, in release, at Framework 3.5.</p></li>
  <li><p>I have dropped a release build of this library in the same directory as StyleCop</p></li>
  <li><p>I use <code>StyleCop.MSBuild</code> (version 4.7.50) for the StyleCop integration, so I am copying it to <code>\packages\StyleCop.MSBuild.{version}\tools</code>.</p></li>
  <li><p>The version of StyleCop referenced within the library, is the same as the one I am copying it next to. (I have checked the versions using ILSpy.)</p></li>
  <li><p>I am using Visual Studio 2015, but I am not using Analyzers</p></li>
  </ul>
  
  <hr>
  
  <p>I don't see the rules when I open the <code>Settings.StyleCop</code> file, nor do I see any indication that they run with <code>Visual Studio</code>.</p>
  
  <p><a href="https://i.stack.imgur.com/a4v71.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/a4v71.png" alt="enter image description here"></a></p>
  
  <hr>
  
  <p><strong>What have I missed?</strong></p>