Most of the coding in the application revolves around moving values between
the two listboxes. You wouldn't need to do any of that because you'd read a
table (or tables) with the values of the person and his/her documents.
The heart of the process is the ZipFileExecute_Click() subroutine which
basically opens a recordset containing the files you want zipped, creates a
text string out of them (ZippedFiles), and then builds a command line
command (AppName) to send to PKZIP with the Shell command:
x = Shell(AppName, 1)
AppName is a variable whose value looks something like this when it
executes:
C:\zip\pkzip.exe MyZipFil.zip test.sql test.csv tblCustomer.txt
You're obviously using some sort of zip utility already, so find out if
there is a command line option for it. WinZip has a command line add-on
http://www.winzip.com/prodpagecl.htm which will allow you to do this. The
parameters might be different, but the process would be essentially the
same.
This process creates a single zip file, of xourse, so you'd have to add
another loop outside of this loop. You'd read the person, read all of
his/her files, create the zip, then read the next person -- and so on.
Good luck.
--
--Roger Carlson
MS Access MVP
Access Database Samples:
www.rogersaccesslibrary.com
Want answers to your Access questions in your Email?
Free subscription:
http://peach.ease.lsoft.com/scripts/wa.exe?SUBED1=ACCESS-L