1.

Solve : Create backup to a network drive?

Answer»

Hello people,

I am very new to this world and will like to create a batch FILE which can zip EVERYTHING under the C:\Backup directory and then copy to a network drive K:\Backup and the name of the zip file must be something like 20070514.zip

Please help me in by correcting my code

The code I am stuck at LOOKS like

set folder=%date:~10,4%_%date:~4,2%_%date:~7,2%
"C:\program Files"\winzip\WZSEPE32.EXE -a -p -r "C:\BACKUP\\%folder%.zip" C:\Programs
copy C:\BACKUP\%folder%.zip K:\BACKUP\\%folder%.zip

Thanks and waiting for replies!!!
Looks like you are off to a pretty good start. What version of Windows are you running? Do you have WinZip installed, and the command line add-on for WinZip installed? The command line versions of WinZip that I have used were either WZZIP.EXE or WINZIP32.EXE, so please verify that you have the command line add-on installed and are using the right executable. Also, unless you want a copy of your backup on the C: and the K:, you can save it DIRECTLY to K: instead of COPYING it. If you do want a copy on your C:, use that as the destination instead of K:.

Assuming the command line executable is WZZIP.EXE, you would probably need to make a couple of modifications to your code like:
Code: [Select]set folder=%date:~10,4%%date:~4,2%%date:~7,2%
"C:\program Files\winzip\wzzip.exe -a -p -r "K:\BACKUP\%folder%.zip" C:\Backup



Discussion

No Comment Found