I am having trouble parsing "1,234.56" in Java, a similar question recommend using French locale in number formatting, but it is parsing the result incorrectly. Here is what I have:
NumberFormat format = NumberFormat.getInstance(Locale.FRANCE);
Number number = format.parse("1,234.56");
System.out.println(number.doubleValue()); // Should get 1234.56, got 1.234 instead
Number number = format.parse("1,234,567.89");
System.out.println(number.doubleValue()); // Should get 1234567.89