poi-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Natalie Horsch" ...@digimax.com>
Subject How to read numeric formatting?
Date Mon, 17 Feb 2003 23:25:04 GMT
Hello,

I was wondering if someone could help me.

I have cells displaying formula results with restricted decimal places
due to formatting on the cell, but actually containing numbers with more
decimal places.  When I read this value using HSSFCell.getNumericValue,
it is returning the whole number, but I only want the rounded one.  

Is there a way to get just what is displayed?  

Alternatively, can I check what the cell format is set to so I can round
to the correct decimal places in the same way as in the worksheet?  I
got the DataFormat from CellStyle, but don't know how to interpret it.

Thanks,

Natalie


Mime
View raw message