2011年8月29日 星期一

getText()

輸入Height:177 Weight:66



myResult.setText(R.string.result);


得到結果 Ur BMI is


myResult.setText(R.string.result+"->"+nf.format(bmi));


得到結果 2130968581->21.07


myResult.setText(getText(R.string.result)+"->"+nf.format(bmi));


得到結果 Ur BMI is->21.07



所以有字串&數字相連就必須正確指定其型態

沒有留言:

張貼留言