title: WP7 Have the enter key send text from textbox to a textblock
body: <p>The <a href="http://tech-fyi.net/2010/07/21/wp7-hello-world/" rel="nofollow noreferrer">following tutorial</a> shows how to take the text from a text box and display it in a text block when the user hits a button. Simple enough... but what I want to do is instead of hitting a button that adds the text I want the enter button to do it.</p>
  <p>Searching here, I found the following code but it doesn't seem to do anything.</p>
  <pre><code>private void textBox_KeyDown(object sender, KeyEventArgs e)
      {
          if (e.Key == Key.Enter)
          {
              listBox.Items.Add(textBox.Text);
          }
      }
  </code></pre>
  <p>So, the textbox that has the string is called textbox and I want the text from that textbox to be added to my list (listBox). When I click the enter button, it does nothing. Any help?</p>