Mar 2nd, 2005, 09:01 AM
Timing, finish zipping before continuing
I have a VB-Script that
1- Zips some files
2- Moves the resulting Zip to a target location
And I just noticed a nice little bug that I donít know how to fix, specifically the timing aspect.
:: VB-Script Code ::
oShell.Run zipDir + "Zip.exe " + strCommandLine
oFSO.MoveFile Source, Destination
This will run my Zip.exe to perform the required task, however on the very next line I perform a MOVE of the resulting zip file (that may not yet exist, this is my problem).
So I need a way to make my VB-Script wait for the Zip file to be generated (really not long). Any clues? Shell return values? I canít have a 50% failure rateÖ Any clues?
Click Here to Expand Forum to Full Width