VBS Script Help
hello all-
i have this batch file i created i would like to create a vbscript instead i am really not good at scripting the bach file just copy folder and file to network directory
REM ACH IAT AND SD FILES BACKUP
@echo off
rem *** copy files for backup ********
xcopy /e /y "c:\ach_down\A_1_pm\*.*" \\enet-nas\cushare\DATA\EFT Services\Atmshr\Ach_Down\ /S
xcopy /e /y "c:\ach_down\B_4_pm\*.*" \\enet-nas\cushare\DATA\EFT Services\Atmshr\Ach_Down\ /S
xcopy /e /y "c:\ach_down\C_10_pm\*.*" \\enet-nas\cushare\DATA\EFT Services\Atmshr\Ach_Down\ /S
xcopy /e /y "c:\ach_down\D_6_am\*.*" \\enet-nas\cushare\DATA\EFT Services\Atmshr\Ach_Down\ /S
xcopy /e /y "c:\ach_down\E_12_pm\*.*" \\enet-nas\cushare\DATA\EFT Services\Atmshr\Ach_Down\ /S
xcopy /e /y "c:\ach_down\IAT_1_PM\*.*" \\enet-nas\cushare\DATA\EFT Services\Atmshr\Ach_Down\ /S
xcopy /e /y "c:\ach_down\IAT_4_PM\*.*" \\enet-nas\cushare\DATA\EFT Services\Atmshr\Ach_Down\ /S
xcopy /e /y "c:\ach_down\IAT_6_AM\*.*" \\enet-nas\cushare\DATA\EFT Services\Atmshr\Ach_Down\ /S
xcopy /e /y "c:\ach_down\IAT_10_PM\*.*" \\enet-nas\cushare\DATA\EFT Services\Atmshr\Ach_Down\ /S
xcopy /e /y "c:\Micr\*.*" \\enet-nas\cushare\DATA\EFT Services\Micr\sdfile\ /S
echo copying files
echo copy operation complete
PAUSE
exit
anyhelp would be greatly appreciated.
thanks
Answers (1)
Google for 'vbscript copyfolder'
Comments:
-
;-) - jaybee96 11 years ago
-
Const OverwriteExisting = True
Set FSO= CreateObject("Scripting.FileSystemObject")
FSO.Copyfolder "\\sourcefolderpath\folder", "destinationpath\", OverwriteExisting - areiner 11 years ago -
thanks areiner - brighstarcuit 11 years ago