How to Avoid Scientific Notation in Double?

前端 未结 5 1485
走了就别回头了
走了就别回头了 2020-11-30 10:23

Here is my simple code

        @Override
    public void onClick(View v) {
        try {
            double price = Double.parseDouble(ePrice.getText().toStr         


        
5条回答
  •  臣服心动
    2020-11-30 10:56

    Use NumberFormater like

    NumberFormat myformatter = new DecimalFormat("########");  
    
    String result = myformatter.format(yourValue);
    

提交回复
热议问题