extract to new file name

Jan 19, 2009 at 10:26 AM
Zip.Extract does not have a overload for extract to a new file name, for some circumstances we need to extract original file name to a new file name.
Coordinator
Jan 20, 2009 at 4:15 AM
Edited Jan 20, 2009 at 4:18 AM
Are you asking a question?
Jan 20, 2009 at 5:16 AM
sorry not explain clearly. I hope that Zip.Extract could add a new overload to extract to a new file name.
Coordinator
Jan 20, 2009 at 5:33 AM
ok, I understand what you are asking for.

I think that the new overload is not necessary.  It is possible to do what you want in a couple of different ways.
First, you can do something like
  ZipEntry e = zip["original.txt"];
  e.FileName= "NewName.txt";
  e.Extract();


And second, of course you can extract it as normal, and then rename the result with System.IO.File.Move(). 


 
Jan 20, 2009 at 1:43 PM
thanks for your detail reply:)