-3

i need to generate excel that display double values with a comma as grouping symbol. example :100000000.00 ------> 100,000,000.00

the comma symbol for group and the Dot symbol for decimal separator thanks,

  • 2
    And hint: what did you try so far, besides posting your requirements here? You know, this is not you-order-we-code.stackexchange.com – GhostCat Jul 08 '16 at 14:17

1 Answers1

1

Have a look to DecimalFormat

String number = "100000000.00";
double nb = Double.parseDouble(number);
DecimalFormat formatter = new DecimalFormat("#,###.00");

System.out.println(formatter.format(nb));
L01c
  • 1,033
  • 10
  • 19