Hi!
By my experience Excel behaves strange, handling CSV.
Opening CSV by double-click leads to someting like a convenience-mode.
This way Excel don't cares about the right charset, or has the wrong
default respectively.
Rename the file to .txt and select the file with the same filter
(Textfiles *.prn, *.txt, *.csv). then you will get a dialog, where you
can choose delimiters, charset and field-types. Now you can select
UTF-8! But only since Ofice 2003. I have to work with an Office 2000,
partly. It can't deal with UTF-8 at all, reading from text-files.
I would think about writing an Excel File with POI/HSSF to avoid these
Problems.
Regards, mago
Shibu Kumar Nair schrieb:
Hi all,
I have a struts 2 application from which user can download CSV file.
The problem is
I download the CSV on the website then save to desktop of my
computer and Open it on NOTEPAD...
that works fine I could still see all the utf-8 text OK with no problem, but
if I open the CSV file in Microsoft EXCEL,
all the utf-8 text are no longer readable.
Does any one have the solution for this, how could I make it readable in MS
Excel
I am using org.apache.commons.io.FileUtils
FileUtils.writeStringToFile(file, test);
i also tried it with
FileUtils.writeStringToFile(file, test,encoding) method
Still the problem exists
Regards
Shibu
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]