[delphizip] CopyZippedFiles

  • From: gslurink <gslurink@xxxxxx>
  • To: delphizip@xxxxxxxxxxxxx
  • Date: Thu, 19 Sep 2002 10:33:45 +0300

Hi all,

I am trying to use CopyZippedFiles to copy files from one
zip to another. I have noticed two things:

1) It seems that CopyZippedFiles does not take wildcards.
Is this complicated to add in a future version ?

2) When I try to use CopyZippedFiles to copy files
to a new created file (by assigning a new name to
ZipMaster.ZipFileName) I get the message:
'Destination zip archive could not be opened.'
I  guess because  CopyZippedFiles tries to open
the original destination file with fmOpenRead:

// Open the second input archive, i.e. the original destination.
  In2FileHandle := FileOpen(DestZipMaster.ZipFileName, fmShareDenyWrite or 
fmOpenRead);

I am not sure if it would be sufficient to add a check
here and open with fmOpenCreate if it is a new file
or if I must create an empty destination file on the disk
first. How can I create an empty zip file ?

Gerard.




Other related posts: