title: convert EditText to float - android eclipse
body: <p>I want to convert <code>EditText</code> to float. I do this:</p>
  
  <pre><code>EditText edt = (EditText) findViewById(R.id.price);
  float number = Float.valueOf(edt.getText().toString());
  </code></pre>
  
  <p>the app not load in my device and the simulator too. in both of them write:</p>
  
  <pre><code>"the application has stopped unexpectedly. please try again."
  </code></pre>
  
  <p>If I remove this line: </p>
  
  <pre><code>float number = Float.valueOf(edt.getText().toString());
  </code></pre>
  
  <p>the app can load.</p>
  
  <p>What can I to do ?</p>