I am trying to format prices using DecimalFormat, but this isn\'t working for all variations.
DecimalFormat df = new DecimalFormat(\"0.##\") df.format(7.8) d
You can try with:
DecimalFormat df = new DecimalFormat("#.##",new DecimalFormatSymbols(Locale.US));