Groups | Blog | Home
all groups > dotnet internationalization > august 2005 >

dotnet internationalization : MS Excel and converstion FROM unicode to ISO-8859


translator
8/27/2005 3:11:28 PM
Hi,
I need an urgent answer to the following question/problem:

1. I have a MS Excel (it's MS Office 2003) file with text strings in
German, French, Spanish, and English. The strings are translations for
a non-Unicode enable proprietary software. Therefore, I need to make
sure that they are not in UTF-8 or any other Unicode format, but are
encoded in ISO-8859.

2. My first problem is that I can't figure out even how to tell what
encoding the strings are in in this Excel spreadsheet. They all are
perfectly readable and correctly represented. But how do I know what
encoding they are in?

3. If I determine that, indeed, the strings are in, say, UTF-8
encoding, how can I convert them to ISO-8859 or ANSI? It is safe to
assume that all the strings fall in the Latin-A range, so, in
prinicple, "down-conversion" should not be a problem.

4. Even if I somehow convert the strings to ISO-8859, how can I insert
them back to an Excel spreadsheet without them being automatically
re-converted to Unicode?

5. The spreadsheet is quite large, with multiple worksheets, so ideally
I would like to find some tool that: (a) determines the encoding used
in the Excel file, and (b) converts the Excel file from Unicode to an
Excel file in
ISO-8859 (or multiple CSV files, one for each worksheet).

Any help or pointers would be GREATLY appreciated!

Thanks!
Michael (michka) Kaplan [MS]
8/27/2005 8:03:49 PM
"translator" <fridman@gmail.com> wrote...
[quoted text, click to view]

Hello!

[quoted text, click to view]

If they are in Excel 2003, they are Unicode (UTF-16 LE, to be precise).

[quoted text, click to view]

See #1.

[quoted text, click to view]

When it is moved out of Excel and into the proprietary software, you need to
make sue they are convrted properly.

[quoted text, click to view]

The same answer as #3, but reversed....

[quoted text, click to view]

I do not know of a tool that would do it, but it would not be that hard to
write one....


--
MichKa [Microsoft]
NLS Collation/Locale/Keyboard Technical Lead
Globalization Infrastructure, Fonts, and Tools
Blog: http://blogs.msdn.com/michkap

This posting is provided "AS IS" with
no warranties, and confers no rights.

translator
8/28/2005 8:40:10 AM
Thanks, Michael!
This is helpful, but ... I am still left with "what do I do now"
problem. I have no access to the client's proprietary software, yet I
need to deliver them the strings in ISO-8859. Telling my client "you go
figure out how to move my UTF-16 data to ISO-8859" is unlikely to enter
the Customer Service Hall of Fame.

It seems that one implication of the information in your message is
that I can't somehow transform encoding within Excel 2003 file -- no
matter how you input the data into the spreadsheet, it will be encoded
in UTF-16 LE.

This raises two options:
1. Can I downsave Excel 2003 spreadsheet to some lower version (Excel
5.0, 3.0?) that is guaranteed to transform the data into ISO-8859? And
how can I check, after downsaving, what encoding it is in?

2. What happens when I save the spreadsheet into csv? How can I
determine the encoding in a csv file? How can I get access to the byte
representation so that I can write a little table lookup function that
will translate one representation to another?

Any tips would be more than appreciated!

Thank you.
Michael (michka) Kaplan [MS]
8/28/2005 11:14:49 AM
You cannot encode Excel using any of the ISO 8859 encodings -- Excel deals
with the Windows code pages, like 1252, et. al.

I cannot speak for Excel's text import/export capabilities (you might have
to ask on an Excel group or spend some time in help to find out the answers
for that), but the Access text export wizard will fully support any of those
ISO 8859-# code pages that you select, and you can save an export spec and
even automate the use of the spec later.


--
MichKa [Microsoft]
NLS Collation/Locale/Keyboard Technical Lead
Globalization Infrastructure, Fonts, and Tools
Blog: http://blogs.msdn.com/michkap

This posting is provided "AS IS" with
no warranties, and confers no rights.


[quoted text, click to view]

AddThis Social Bookmark Button