Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Using WinZip
Message
 
To
06/07/2001 14:02:50
General information
Forum:
Visual FoxPro
Category:
Other
Title:
Miscellaneous
Thread ID:
00527556
Message ID:
00527571
Views:
30
This message has been marked as a message which has helped to the initial question of the thread.
You need WinZip8 and the addon for command line WzZip and WZUnzip.
I use them with this prg code:
first I create a .bat file and then execute it with ! command

parameters DirOrigen, FileName, DirDestino, Criterio, Modo, Estruct, List

WZipDir = trim(FULLPATH(""))

IF FILE('Zip.bat')
delete file zip.bat
endif
gnErrFile = FCREATE('Zip.bat')

IF gnErrFile < 0
messagebox("Error de lectura")
ELSE

if modo = "Z"
pathOrigen = trim(dirOrigen)+trim(Criterio)
pathDestino = trim(dirDestino)+trim(FileName)

=Fwrite(gnErrFile , (WZipDir))
=Fwrite(gnErrFile , 'wzzip ')
if Estruct = 'S'
=FWRITE(gnErrFile, '-rp ' )
endif
if List = 'S'
=FWRITE(gnErrFile, '-v ' )
endif
=FWRITE(gnErrFile, (pathDestino) )
=Fwrite(gnErrFile, ' ' )
=Fputs(gnErrFile, (pathOrigen))
else
pathOrigen = trim(dirOrigen)+trim(FileName)
pathDestino = trim(dirDestino)

=Fwrite(gnErrFile , (WZipDir))
=Fwrite(gnErrFile , 'wzunzip ')
if Estruct = 'S'
=FWRITE(gnErrFile, '-d ' )
endif
if List = 'S'
=FWRITE(gnErrFile, '-v ' )
endif
=FWRITE(gnErrFile, (pathOrigen) )
=Fwrite(gnErrFile, ' ' )
=Fputs(gnErrFile, (pathDEstino))
endif
ENDIF
=FCLOSE(gnErrFile )

!Zip.bat


bye
fabian
Previous
Reply
Map
View

Click here to load this message in the networking platform