poi-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dmitri Pissarenko <mailing-li...@dapissarenko.com>
Subject Problems with scientific notation in formulae
Date Wed, 09 Feb 2005 17:12:37 GMT
Hello!

I have a problem with using numbers in scientific notation in cell formulae.

For instance, I want to create a cell with the formula "1*3.6E-4". For this
purpose, I first format 3.6E-4 with

DecimalFormat format=null;
format=new DecimalFormat("#.####E0");

and then set the cell formula using

cell.setCellFormula("1*" + format.format(3.6E-4));

The problem is that

cell.getCellFormula()

returns

"1*3"

instead of "1*3.6E-4".

How can solve this problem?

Thanks in advance

Dmitri Pissarenko
--
Dmitri Pissarenko
Software Engineer
http://dapissarenko.com

---------------------------------------------------------------------
To unsubscribe, e-mail: poi-user-unsubscribe@jakarta.apache.org
Mailing List:     http://jakarta.apache.org/site/mail2.html#poi
The Apache Jakarta Poi Project:  http://jakarta.apache.org/poi/


Mime
View raw message