Hi All
Is it possible to change this code:
Sub SaveBackup()
ActiveWorkbook.SaveCopyAs "d:\MyBook.xls"
End Sub
to save a copy of the Folder in which is the Book-to back up not only
MyBook but the whole current folder with the book?
Hi All
Is it possible to change this code:
Sub SaveBackup()
ActiveWorkbook.SaveCopyAs "d:\MyBook.xls"
End Sub
to save a copy of the Folder in which is the Book-to back up not only
MyBook but the whole current folder with the book?
Tim,
If your source and destination folders are fixed, then it is simple.
The code below will do that. For extra options you can look in your
command box and type "xcopy /?"
ChDrive C:
ChDir "c:\test\"
Myapp = Shell("cmd /c xcopy c:\test d:\test", vbNormalFocus)
If you want to keep your dos box open after proces you can use the "cmd
/k" option this can be handy when an error occur.
Chris
Thak you Chris !!!
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks