I am getting the below error when trying to convert string to double.
For input string: "1,514,230.15"
Exception:
java.lang.NumberFormatException: For input string: "1,514,230.15"
at sun.misc.FloatingDecimal.readJavaFormatString(Unknown Source)
at sun.misc.FloatingDecimal.parseDouble(Unknown Source)
at java.lang.Double.parseDouble(Unknown Source)
This is the line of code I am using
testString = "1,514,230.15"
double d= Double.parseDouble(TestString);
Can someone help me understand what I am doing wrong here?