Android:Got NumberFormatExxception while getting data from EditText field
问题 java.lang.RuntimeException: Unable to start activity ComponentInfo { com.project/com.project.simple} : java.lang.NumberFormatException EditText et1,et2,et3; Button b1, b2; Float two,three,four; @Override protected void onCreate(Bundle savedInstanceState) { // TODO Auto-generated method stub super.onCreate(savedInstanceState); setContentView(R.layout.can); et1 = (EditText) findViewById(R.id.editText1); two = Float.valueOf(et1.getText().toString()); et2 = (EditText) findViewById(R.id.editText2)