Only having started using HSSF in the last week or so I'm not particularly knowledgeable about differences in format codes between Excel versions.
The following comment appears in HSSFDateUtil.isInternalDateFormat() : //Additional internal date formats found by inspection // Using Excel v.X 10.1.0 (Mac) With Excel 2002 I've found that some of these additional formats are NOT Date formats but percentage formats, presumably some of the codes also represent currency formats. Therefore the only suggestion I've got is to check the format code of the date formats you are expecting then rewrite the switch statement in isInternalDateFormat() to return true for these codes only. -----Original Message----- From: Mar�a Valeria Salviati [mailto:[EMAIL PROTECTED] Sent: 04 December 2003 13:58 To: POI Users List Subject: Re: Currency formated cells So ... How can I recognize currency or time format? Cope, Christopher escribi�:: >HSSFDateUtil.isCellDateFormatted() or HSSFDateUtil.isInternalDateFormat() >will still return true for certain non-date formats, see bug 24125: > >http://nagoya.apache.org/bugzilla/show_bug.cgi?id=24125 > >Chris > >-----Original Message----- >From: Mauro Daniel Ardolino [mailto:[EMAIL PROTECTED] >Sent: 04 December 2003 12:56 >To: POI Users List >Subject: Re: Currency formated cells > > >May be this can help you: > >http://www.mail-archive.com/[EMAIL PROTECTED]/msg02087.html > >Luck! > >-- Mauro > > >On Wed, 3 Dec 2003, Mar�a Valeria Salviati wrote: > > > >>Hi, >> >>Cells formated as Currency or as Time are recognized as Dates. >> >>How can I recognize currency or time format? >> >> >>if(cellFormat==HSSFCell.CELL_TYPE_NUMERIC) { >> if (HSSFDateUtil.isCellDateFormatted(cell)) { >> //here recognizes: date - time - currency formats >> } >>} >> >> >>Thanks in advance, >> >>Valeria >> >> >>--------------------------------------------------------------------- >>To unsubscribe, e-mail: [EMAIL PROTECTED] >>For additional commands, e-mail: [EMAIL PROTECTED] >> >> >> >> > > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This e-mail and any attachment is for authorised use by the intended recipient(s) only. It may contain proprietary material, confidential information and/or be subject to legal privilege. It should not be copied, disclosed to, retained or used by, any other party. If you are not an intended recipient then please promptly delete this e-mail and any attachment and all copies and inform the sender. Thank you. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
