You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@poi.apache.org by "Abma, T.W." <T....@umcutrecht.nl> on 2010/03/31 12:01:34 UTC

detecting locale used in Excel-sheets and reading values conform specific locale

Hello,

I am currently working with POI and this works fine, but I have one issue and that's detecting the locale used in the Excel sheet.

Sometimes I have US-style notation in my Excel-sheets and sometimes EU-style when reading dates/numbers (comma/dot problem).

I know that the JExcelAPI has a method called getLocale():

http://jexcelapi.sourceforge.net/resources/javadocs/current/docs/jxl/WorkbookSettings.html#getLocale()

Is there something similar in POI to know which locale is used in the sheet? And when I've detected the locale, how can I
be sure that the values read from the cells are automatically converted to say EU-style? Or is there another method/way
of handling different formats and make sure that they are in the end all converted to a specific locale?

Any help would be welcome. Thanks in advance and with kind regards,

Tjeerd Abma

Scientific programmer/Bioinformatician
UMCU Metabolomics Centre
Dept. Metabolic and Endocrine Diseases
Wilhelmina Childrens Hospital, UMC Utrecht

------------------------------------------------------------------------------

De informatie opgenomen in dit bericht kan vertrouwelijk zijn en is
uitsluitend bestemd voor de geadresseerde. Indien u dit bericht onterecht
ontvangt, wordt u verzocht de inhoud niet te gebruiken en de afzender direct
te informeren door het bericht te retourneren. Het Universitair Medisch
Centrum Utrecht is een publiekrechtelijke rechtspersoon in de zin van de W.H.W.
(Wet Hoger Onderwijs en Wetenschappelijk Onderzoek) en staat geregistreerd bij
de Kamer van Koophandel voor Midden-Nederland onder nr. 30244197.

Denk s.v.p aan het milieu voor u deze e-mail afdrukt.

------------------------------------------------------------------------------

This message may contain confidential information and is intended exclusively
for the addressee. If you receive this message unintentionally, please do not
use the contents but notify the sender immediately by return e-mail. University
Medical Center Utrecht is a legal person by public law and is registered at
the Chamber of Commerce for Midden-Nederland under no. 30244197.

Please consider the environment before printing this e-mail.

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@poi.apache.org
For additional commands, e-mail: user-help@poi.apache.org