General information
Category:
ActiveX controls in VFP
Environment versions
Network:
Windows 2003 Server
Anyone know how to get Dynazip OCX to create multi-volume zip files?
I follow the manual instruction, but it doesn´t seem to work. It keeps creating a single ZIP file. I am not sure if I got fileSizeArray property right!
Here it is the code for the ZIP button
PRIVATE m.retn_code, mvsettings
#DEFINE ZIP_ADD 4
#DEFINE ZIP_UPD 3
#DEFINE MV_USEMULTI 32768
#DEFINE MV_FORMAT 1
#DEFINE MV_LOWDENSE 2
#DEFINE MV_WIPE 256
#DEFINE MV_SUBDIR 512
#DEFINE MV_SYSHIDE 1024
#DEFINE MV_CDFIRST 4096
#DEFINE MV_TOHD 16384
m.dados = 'C:\VFoxPro\Desenv5\DOC\zip\'
* Set all default values
THISFORM.initzipcmdstruct
* Setup zip properties to those on the form
m.ziparq = GETFILE()
THISFORM.Dzocx11.ItemList = aspas(m.ziparq)
THISFORM.Dzocx11.ExcludeFollowing = "*.FXP segurança.* foxuser.*"
THISFORM.Dzocx11.ExcludeFollowingFlag = .T.
mvsettings = MV_USEMULTI + MV_TOHD
DIMENSION volumesize(2)
volumesize(1) = 1213952
volumesize(2) = 0
thisform.dzocx11.fileSizeArray = volumesize
Thisform.Dzocx11.MultiVolumeControl = mvsettings
THISFORM.Dzocx11.ZIPFile = m.arquivo
THISFORM.Dzocx11.MajorStatusFlag = .T.
THISFORM.Dzocx11.MessageCallbackFlag = .T.
* Do the ZIP
_VFP.AUTOYIELD = .F.
THISFORM.Dzocx11.ActionDZ = ZIP_ADD
_VFP.AUTOYIELD = .T.
***************
* initzipcmdstruct
***************
#DEFINE NO_ACTION 0
#DEFINE ZSO_MINORCANCEL 2
#DEFINE ZSO_EXTERNALPROG 4
#DEFINE ZSO_EXTPROGCANCEL 8
ThisForm.Dzocx11.ActionDZ = NO_ACTION
ThisForm.Dzocx11.AddCommentFlag = .F.
ThisForm.Dzocx11.AfterDateFlag = .F.
ThisForm.Dzocx11.BackgroundProcessFlag = .T.
ThisForm.Dzocx11.Comment = ""
ThisForm.Dzocx11.CompressionFactor = 5
ThisForm.Dzocx11.ConvertLFtoCRLFFlag = .F.
ThisForm.Dzocx11.Date = ""
ThisForm.Dzocx11.DeleteOriginalFlag = .F.
ThisForm.Dzocx11.DiagnosticFlag = .F.
ThisForm.Dzocx11.DontCompressTheseSuffixesFlag = .F.
ThisForm.Dzocx11.DosifyFlag = .F.
ThisForm.Dzocx11.EncryptCode = ""
ThisForm.Dzocx11.EncryptFlag = .F.
ThisForm.Dzocx11.ExcludeFollowing = ""
ThisForm.Dzocx11.ExcludeFollowingFlag = .F.
ThisForm.Dzocx11.FixFlag = .F.
ThisForm.Dzocx11.FixHarderFlag = .F.
ThisForm.Dzocx11.GrowExistingFlag = .F.
ThisForm.Dzocx11.IncludeFollowing = ""
ThisForm.Dzocx11.IncludeOnlyFollowingFlag = .F.
ThisForm.Dzocx11.IncludeSysandHiddenFlag = .F.
ThisForm.Dzocx11.IncludeVolumeFlag = .F.
ThisForm.Dzocx11.ItemList = ""
ThisForm.Dzocx11.MajorStatusFlag = .F.
ThisForm.Dzocx11.MessageCallbackFlag = .F.
ThisForm.Dzocx11.MinorStatusFlag = .F.
ThisForm.Dzocx11.MultiVolumeControl = 0
ThisForm.Dzocx11.NoDirectoryEntriesFlag = .T.
ThisForm.Dzocx11.NoDirectoryNamesFlag = .T.
ThisForm.Dzocx11.OldAsLatestFlag = .F.
ThisForm.Dzocx11.PathForTempFlag = .T.
ThisForm.Dzocx11.QuietFlag = .T.
ThisForm.Dzocx11.RecurseFlag = .F.
ThisForm.Dzocx11.StoreSuffixes = ""
ThisForm.Dzocx11.TempPath = m.dados
ThisForm.Dzocx11.ZIPFile = ""
ThisForm.Dzocx11.ZipSubOptions = ZSO_MINORCANCEL
* added for rev 3.00
ThisForm.Dzocx11.RenameCallbackFlag = .F.
ThisForm.Dzocx11.ExtProgTitle = "Atenção"
ThisForm.Dzocx11.ZIPString = ""
ThisForm.Dzocx11.MemoryBlockSize = 0
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only