Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
DecimalFormat fmt = new DecimalFormat();
fmt.setParseBigDecimal(true);
globalMap.put("bdfmt", fmt); // corrected
(BigDecimal)((DecimalFormat)globalMap.get("bdfmt")).parse(row1.stringNumberValue); // corrected
import java.util.Locale;
Locale.setDefault(Locale.ITALIAN);
import java.text.DecimalFormat;
import java.math.BigDecimal;
// if locale isn't set to ITALIAN
import java.util.Locale;
DecimalFormat fmt = new DecimalFormat();
fmt.setParseBigDecimal(true);
globalMap.put("bdfmt", fmt); // corrected
// if locale isn't set to ITALIAN
Locale.setDefault(Locale.ITALIAN);
(BigDecimal) ( (DecimalFormat)globalMap.get("bdfmt") ).parse( row1.stringNumberValue ); // corrected
(BigDecimal) ( (DecimalFormat)globalMap.get("bdfmt") ).parse( row1.stringNumberValue );