title: How can I prevent the keydown event of a form in C# from firing more than once?
body: <p>According to the <a href="http://msdn.microsoft.com/en-us/library/ms171536.aspx" rel="nofollow noreferrer">official documentation</a>, the KeyDown event on a Windows Forms control occurs only once, but it is easy to demonstrate that the event fires continually aslong as a key is held down:</p>
  
  <pre><code>    private void textBox1_KeyDown(object sender, KeyEventArgs e)
      {
          label1.Text = string.Format("{0}", globalCounter++);
      }
  </code></pre>
  
  <p>How can you consume the event so that it fires only once? </p>