From: Takashi & Kayoko Sano Date: 2003-12-08T15:04:48+09:00 Subject: ruby-zip problem Hi folks, I'm now playing with ruby-zip. I can make it work right for decompression of zip files, but somehow not for compression. It actually creates a zip file, but it's corrupted. Could anyone point me to the right direction? I'm a novice programmer and ruby-zip is scarcely documented, so maybe I'm not aware of things that require attention. The sample script is shown below. require 'zip/zip' Zip::ZipFile.open("test.sxw") {|zf| zf.replace("content.xml", "content_new.xml") } What I want to do is, opening a OpenOffice.org Writer file, which is actually a zip file containing 5 files and 1 folder with 1 file, and replacing the document's content file, which is encoded in UTF-8, with a new one. The strange thing is when the resultant zip file is decompressed, the replaced file is decompressed fine, but the rest of files are corrupted. BTW, I'm doing this on Windows XP and arton's ActiveScriptRuby 1.8.0.5. Thanks in advance, Takashi Sano