title: NumericUpDown background colour change for disabled element
body: <p>On my winform application I'm trying to do colour-coding on the required fields. On user editing, when a required input is filled in, the background becomes light green, if required field is empty, it's background is red.
  Some fields are enabled and disabled depending on the input in other fields, so sometimes I have required field that is disabled, and that should be completely disabled (disabled colour background). 
  This is what I have for the background change:</p>
  
  <pre><code>public static void UpdateBackgroundColor(this NumericUpDown control)
  {
      if (!control.Enabled)
      {
          control.BackColor = SystemColors.InactiveBorder;
          return;
      }
  
      var inputValue = control.Value;
  
      if (inputValue == 0)
      {
          control.BackColor = Color.Red;
          return;
      }
      control.BackColor = Color.LightGreen;
  }
  </code></pre>
  
  <p>Similar function works on TextBox and works fine with no glitches. 
  But NumericUpDown is misbehaving.
  This is what I see when the field is required and empty:</p>
  
  <p><img src="https://i.stack.imgur.com/zG4jr.png" alt="enter image description here"></p>
  
  <p>But when this field becomes disabled, it keeps a red border around it:</p>
  
  <p><img src="https://i.stack.imgur.com/0kyfI.png" alt="enter image description here"></p>
  
  <p>The same story happens when background is green and becomes disabled.</p>
  
  <p>So why does this happen and how to fix it?</p>
  
  <p><strong>UPD:</strong> As per Han's answer, I quickly updated my code, but that still does not work.</p>
  
  <pre><code>    private static void SetBackgroundColor(this Control control, Color color)
      {
          control.BackColor = color;
          foreach (Control childControl in control.Controls)
          {
              SetBackgroundColor(childControl, color);
          }
      }
  </code></pre>
  
  <p>And I'm roughly using it like this: </p>
  
  <pre><code>numericUpDown1.Enabled = true;
  numericUpDown1.SetBackgroundColor(Color.Red);
  numericUpDown1.Enabled = false;
  numericUpDown1.SetBackgroundColor(SystemColors.InactiveBorder);
  </code></pre>
  
  <p>And still get that frame around the text box, despite the fact that I go through all the child controls of NUD and change the back colours there. Any other ideas?</p>
  
  <p>Cheers!!</p>