title: Sencha ExtJs TextField KeyDown Event in FireFox
body: <p>So I have the following code that detects where the key that was pressed is a number, space or delete key. If not it stops the key from being entered into the textfield. It works perfectly in Chrome and IE. When I run it in FireFox I get the following error: returnValue is undefined in the following statement: e.event.returnValue = false;</p>
  
  <p>Here is the code:</p>
  
  <pre><code>keydown:function( sender, e, eOpts )
                      { 
                          if (!isNumberKey(e))
                          {
                              e.event.returnValue = false;
                          }
                      } 
  </code></pre>
  
  <p>The Function that does the work:</p>
  
  <pre><code>function isNumberKey(e)
  {
  //Local Varaible Declaration
  var returnValue = false;
  
  if (e.keyCode &gt;= 96 &amp;&amp; e.keyCode &lt;= 105)
  {
      returnValue = true;
  }
  else if (e.keyCode &gt;= 48 &amp;&amp; e.keyCode &lt;= 57)
  {
      returnValue = true;
  }
  else if (e.keyCode == 8 || e.keyCode == 46)
  {
      returnValue = true;
  }
  
  return returnValue;
  </code></pre>
  
  <p>}</p>
  
  <p>I looked in the debugger in the firefox and found that returnValue really is not there. What do I use instead? I am sure there must be a way to accomplish this in FireFox.</p>
  
  <p>Thanks,</p>
  
  <p>Josh</p>