You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ant.apache.org by Zsolt Koppany <zk...@intland.com> on 2003/10/01 13:09:12 UTC
How to use ZipFile to extract a zip file (with umlauts) created by WinZip
Hi,
I understand that the ZipFile consturctor supports encoding, however I could
not figure out how to get the filenames that contain German umlauts
correctly using ZipFile.
Which encoding do I have to use? I have tried "ASCII", "Cp1252",
"ISO-8859-1" but none of them worked.
Zsolt
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org
RE: How to use ZipFile to extract a zip file (with umlauts) created by WinZip
Posted by Zsolt Koppany <zk...@intland.com>.
Stefan,
I created the zip file with WinZip and my applications runs on the same host
(Windows-XP).
Zsolt
-----Original Message-----
From: Stefan Bodewig [mailto:bodewig@apache.org]
Sent: Wednesday, October 01, 2003 1:21 PM
To: user@ant.apache.org
Subject: Re: How to use ZipFile to extract a zip file (with umlauts)
created by WinZip
On Wed, 1 Oct 2003, Zsolt Koppany <zk...@intland.com> wrote:
> Which encoding do I have to use?
The same that has been used to create the archive in the first place.
If it has been created by jar or <jar> it is most likely UTF-8.
Otherwise your best bet is to use the native encoding of the OS (or
even the machine) that has created the zip.
Stefan
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org
Re: How to use ZipFile to extract a zip file (with umlauts) created by WinZip
Posted by Stefan Bodewig <bo...@apache.org>.
On Wed, 1 Oct 2003, Zsolt Koppany <zk...@intland.com> wrote:
> Which encoding do I have to use?
The same that has been used to create the archive in the first place.
If it has been created by jar or <jar> it is most likely UTF-8.
Otherwise your best bet is to use the native encoding of the OS (or
even the machine) that has created the zip.
Stefan
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org
RE: How to use ZipFile to extract a zip file (with umlauts) created by WinZip
Posted by Zsolt Koppany <zk...@intland.com>.
I have found the solution:
ZipFile zipFile = new ZipFile(zf, "Cp858");
Zsolt
-----Original Message-----
From: Zsolt Koppany [mailto:zkoppanylist@intland.com]
Sent: Wednesday, October 01, 2003 1:09 PM
To: Ant Users List
Subject: How to use ZipFile to extract a zip file (with umlauts) created
by WinZip
Hi,
I understand that the ZipFile consturctor supports encoding, however I could
not figure out how to get the filenames that contain German umlauts
correctly using ZipFile.
Which encoding do I have to use? I have tried "ASCII", "Cp1252",
"ISO-8859-1" but none of them worked.
Zsolt
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org