This is my batch file as it stands today, this whole thing runs in a hosted environment, so I don't know about access to registries, etc. :
@echo off
cls
setlocal enabledelayedexpansion
set alphamonth=JAN FEB MAR APR MAY JUN JUL AUG SEP OCT NOV DEC
for /f "tokens=%date:~4,2%" %%1 in ("%alphamonth%") do (
set month=%%1
)
set today=%date:~7,2%%month%%date:~-2%
for /f "tokens=1-4 delims=: " %%1 in ("%time%") do (
set hour=%%1
set min=%%2
if /i %%4 equ pm set /a Hour +=12
)
if %hour% lss 10 set hour=0%hour%
set time=%hour%%min%
E:
CD \FCS_FPS\OCA\OPS_BACKUP\TEMP\
BUTIL -STARTBU @E:\FCS_FPS\OCA\OPS_BACKUP\STARTLST.FIL
XCOPY E:\FCS_FPS\OCA\OPS\FLTCTRL\DATA\*.DAT E:\FCS_FPS\OCA\OPS_BACKUP\TEMP\ /EXCLUDE:E:\FCS_FPS\OCA\OPS_BACKUP\EXCLUDE.LST
COPY E:\FCS_FPS\OCA\OPS\FLTCTRL\DATA\%today%*.WXT E:\FCS_FPS\OCA\OPS_BACKUP\TEMP\
BUTIL -ENDBU @E:\FCS_FPS\OCA\OPS_BACKUP\STARTLST.FIL
E:\FCS_FPS\OCA\OPS_BACKUP\7ZIP\7ZA A E:\FCS_FPS\OCA\OPS_BACKUP\ZIPS\%today%_%time%.ZIP E:\FCS_FPS\OCA\OPS_BACKUP\TEMP\*.DAT
E:\FCS_FPS\OCA\OPS_BACKUP\7ZIP\7ZA A E:\FCS_FPS\OCA\OPS_BACKUP\ZIPS\%today%_%time%.ZIP E:\FCS_FPS\OCA\OPS_BACKUP\TEMP\*.WXT
DEL E:\FCS_FPS\OCA\OPS_BACKUP\TEMP\*.DAT
DEL E:\FCS_FPS\OCA\OPS_BACKUP\TEMP\*.WXT
COPY E:\FCS_FPS\OCA\OPS_BACKUP\ZIPS\%today%_%time%.ZIP \\EMGHWP079\E$\FCS_FPS\OCA\OPS_BACKUP\ZIPS\
Here is the Output when the above code is execuded:
The system cannot find the path specified.
'BUTIL' is not recognized as an internal or external command,
operable program or batch file.
Can't read file: E:\FCS_FPS\OCA\OPS_BACKUP\EXCLUDE.LST
0 File(s) copied
The system cannot find the path specified.
'BUTIL' is not recognized as an internal or external command,
operable program or batch file.
The system cannot find the path specified.
C:\batch>
Would you show the output when your code is run on your machine?I suggest you look at post # 9.
Or study anything Sidewinder writes.
You may safely ignore everyone else.