I have a double value = 1.068879335 i want to round it up with only two decimal values like 1.07.
1.068879335
I tried like this
DecimalFormat df=new
double TotalPrice=90.98989898898; DecimalFormat format_2Places = new DecimalFormat("0.00"); TotalPrice = Double.valueOf(format_2Places.format(TotalPrice));