title: Prevent default doesnt work when enter key pressed
body: <p>my asp.net control looks like this;</p>
  
  <pre><code>&lt;asp:Button ID="btnLogOut" runat="server" Text="Exit" ClientIDMode="Static" OnClick="btnLogOut_Click" /&gt;
  </code></pre>
  
  <p>and js event;</p>
  
  <pre><code> $("#btnLogOut").keyup(function (event) {
      if (event.which == 13 || event.keyCode == 13) {
          alert(event.keyCode);
          $("#btnLogOut").preventDefault();
          return false;
      }
      else return true;
  });
  </code></pre>
  
  <p>On the page, when I pressed enter key, it triggers btnLogOut button. To prevent this,
  I wrote above js event. alert says that keyCode is 13 but it's not preventing click function and I log out.</p>
  
  <p>How Can I fix this? This especially occurs in IE</p>
  
  <p>Edit: <code>event.preventDefault</code> not working also.</p>