title: Prevent backspace in richtextbox using C# .net
body: <p>I'm pulling my hair out over this one.  Very simple windows forms program.  I have a richtextbox and I want to prevent the backspace from doing anything in the richtextbox.
  Here is my code</p>
  
  <pre><code>private void richTextBox1_KeyPress(object sender, KeyPressEventArgs e)
  {
       if (e.KeyChar == (char)Keys.Back)
       {
            e.handled = true;
       }
  }
  </code></pre>
  
  <p>If I put a breakpoint at e.handled and I type a backspace it indeed breaks.  However the backspace still makes it to the richtextbox.  So I have seen examples where PreviewKeyDown is used however NONE of those examples work! I tried</p>
  
  <pre><code>void richTextBox1.PreviewKeyDown(object sender, KeyPressEventArgs e)
  {
       e.Handled = true;
  }
  </code></pre>
  
  <p>However KeyPressEventArgs is not valid!  If I use what Forms gives it's PreviewKeyDownEventArgs and the is no e.Handles available.  So how does one do this?</p>
  
  <p>Thanks</p>