Access VBA - programmatically add files to an existing zip
Posted on 2011-03-17
Does anyone know how to programmatically add files to an exisiting zip file? I'm using code to create the zip file with a spreadsheet in it. However, I need to add PDFs to that zip file. The reason it needs to be done with VBA code and not dragging/dropping into the zip is because the code will run overnight when no one is around.
btw, i'm trying to use 'FileCopy strDirFrom, strDirTo', to copy the PDF to the zip file but I keep getting Run-time error '76': Path not found. This is confusing me because I know the paths are right. Are you not able to programmatically copy to a compressed zip file?
any ideas will be greatly appreciated.