title: How to override an inherited method from within another inherited class
body: <p>I am wondering if possible to override a method from calling console app or a super super class? I understand I can override WriteLog at DoMath.... however consider that I would like to manage this instead at the console app.</p>
  <p>Example:</p>
  <pre><code>public class LogThings
  {
      public virtual void WriteLog(string value)
      {
          Console.WriteLine(&quot;This is the base in LogThings &quot; + value);
      }
  }
  </code></pre>
  <p>The class inheriting the base. I kind of thought if I add the method again and mark it with new to implement as a virtual, then I can override this in the console app that inherits DoMath?</p>
  <pre><code>public class DoMath : LogThings
  {
      public double DoAddition(double a, double b)
      {
          double result;
          result = a + b;
          WriteLog(result.ToString()); // &lt; the operation I need to overload
          return result;
      }
  
      public new virtual void WriteLog(string value)
      {
          Console.WriteLine(&quot;this is overriding the base in DoMath&quot;);
          base.WriteLog(value);
      }
  }
  </code></pre>
  <p>Some console app using the doMathANdLog class library:</p>
  <pre><code>class Program : DoMath
  {
      static void Main(string[] args)
      {
          var m = new DoMath();
          m.DoAddition(1, 2);
        
          Console.ReadLine();
      }
  
      public override void WriteLog(string value)
      {
          Console.WriteLine(&quot;this is not overriding.&quot;);
      }
  }
  </code></pre>
  <p>Result is this when running it:</p>
  <blockquote>
  <p>this is overriding the base in DoMath<br />
  This is the base in LogThings 3</p>
  </blockquote>
  <p>Is there a way to do this?</p>