String s = null;
if (Math.round(value) == value) {
DecimalFormat df = new DecimalFormat("#");
s = df.format(value);
} else {
s = Double.toString(value);
}
That's what I use anyway. You might need something like it.
Matt
Morten <[EMAIL PROTECTED]> wrote:
Hi,
I'm using the event based API for processing documents.
If I have a cell in my Excel document with the value 2000 it
shows up in POI as a NumberRecord with the double value 2000.0.
I've tried to set the cell type to text, but POI still perceives
it as a NumberRecord. It's not immediatly visible to me how to
distinguish between double and integer cell content using the API.
Br,
Morten
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------
Want to chat instantly with your online friends?�Get the FREE Yahoo!Messenger