title: Negative value in edittext
body: <p>conversion is other class, I'm working in <code>MainActivity</code>;</p>
  
  <p>when i clear edittext and then enter "-" then it generates error, but when i enter some value and then at first position of edittext then it does not generate error, plz help m attaching my error log with it.  </p>
  
  <pre><code>Conversion conversion;
  
  
  conversion = new Conversion();
  
  
  @Override
          public void onTextChanged(CharSequence s, int start, int before,
                  int count) {
  if(edittext.length()!=0){
  String Result =conversion.temp(spinner1.getSelectedItemPosition(),
          spinner2.getSelectedItemPosition(),edittext.getText().toString());
   textView.setText(Result);
   }
  
   }
  </code></pre>
  
  <p>This is my function</p>
  
  <pre><code>public String temp(int ddfrom,int ddto,String edittextvalue) {
  
  float s;
      float inputValue = Float.parseFloat(edittextvalue);
      s = rate*inputValue;
  return String.valueOf(s);
  
  }
  </code></pre>
  
  <blockquote>
  <pre><code>    02-04 12:56:33.029: E/AndroidRuntime(317): Uncaught handler: thread main exiting due to uncaught exception
        02-04 12:56:33.119: E/AndroidRuntime(317): java.lang.NumberFormatException: -
        02-04 12:56:33.119: E/AndroidRuntime(317):    at org.apache.harmony.luni.util.FloatingPointParser.initialParse(FloatingPointParser.java:149)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at org.apache.harmony.luni.util.FloatingPointParser.parseFloat(FloatingPointParser.java:319)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at java.lang.Float.parseFloat(Float.java:288)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at com.sample.unitconverter.Conversion.timee(Conversion.java:651)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at com.sample.unitconverter.UnitConverter$6.onTextChanged(UnitConverter.java:397)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at android.widget.TextView.sendOnTextChanged(TextView.java:6131)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at android.widget.TextView.handleTextChanged(TextView.java:6172)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at android.widget.TextView$ChangeWatcher.onTextChanged(TextView.java:6316)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at android.text.SpannableStringBuilder.sendTextChange(SpannableStringBuilder.java:889)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at android.text.SpannableStringBuilder.change(SpannableStringBuilder.java:352)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at android.text.SpannableStringBuilder.change(SpannableStringBuilder.java:269)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at android.text.SpannableStringBuilder.replace(SpannableStringBuilder.java:432)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at android.text.SpannableStringBuilder.replace(SpannableStringBuilder.java:409)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at android.text.SpannableStringBuilder.replace(SpannableStringBuilder.java:28)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at android.view.inputmethod.BaseInputConnection.replaceText(BaseInputConnection.java:578)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at android.view.inputmethod.BaseInputConnection.commitText(BaseInputConnection.java:174)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at com.android.internal.widget.EditableInputConnection.commitText(EditableInputConnection.java:120)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at com.android.internal.view.IInputConnectionWrapper.executeMessage(IInputConnectionWrapper.java:231)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at      com.android.internal.view.IInputConnectionWrapper$MyHandler.handleMessage(IInputConnectionWrapper.java:57)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at android.os.Handler.dispatchMessage(Handler.java:99)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at android.os.Looper.loop(Looper.java:123)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at android.app.ActivityThread.main(ActivityThread.java:4363)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at java.lang.reflect.Method.invokeNative(Native Method)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at java.lang.reflect.Method.invoke(Method.java:521)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:860)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618)
        02-04 12:56:33.119: E/AndroidRuntime(317):    at dalvik.system.NativeStart.main(Native Method)
  </code></pre>
  </blockquote>