title: How can I accept the backspace key in the keypress event?
body: <p>This is my code:</p>
  
  <pre><code>private void txtAdd_KeyPress(object sender, KeyPressEventArgs e)
  {
      if (!(char.IsLetter(e.KeyChar)) &amp;&amp; !(char.IsNumber(e.KeyChar)) &amp;&amp; !(char.IsWhiteSpace(e.KeyChar)))
      {
          e.Handled = true;
      }
  }
  </code></pre>
  
  <p>It allows me to enter letters, numbers and spaces but it doesn't allow me to do backspace. Please help me.</p>