Cd Backup 

Set FOLDER4COPY=D:\BdPos\
Rem Set FOLDER4COPY=M:\

If Exist update.zip Goto COPY4FILE
If Not Exist update.zip Goto NOCOPY4FILE

:COPY4FILE 
for /f "tokens=1,2,3,4 delims=/ " %%a in ("%date%") do set wday=%%a&set month=%%b&set day=%%c&set year=%%d
echo.Weekday: %wday%
echo.Month  : %month%
echo.Day    : %day%
echo.Year   : %year%

Rem If Not Exist Pos"%day%_%month%_%year%".Exe Copy %FOLDER4COPY%Poswin.exe %FOLDER4COPY%Pos"%day%_%month%_%year%".Exe
Rem If Not Exist Mas"%day%_%month%_%year%".Exe Copy %FOLDER4COPY%Master.exe %FOLDER4COPY%Mas"%day%_%month%_%year%".Exe
Rem If Not Exist Sc"%day%_%month%_%year%".Exe Copy %FOLDER4COPY%Sc.exe %FOLDER4COPY%Sc"%day%_%month%_%year%".Exe

D:\BdPos\Pkunzip -o  update.Zip D:\BdPos
If Exist Dbfrun.Zip D:\BdPos\Pkunzip -o  Dbfrun.Zip D:\BdPos\Dbfrun
If Exist Data2SC.Zip D:\BdPos\Pkunzip -o  Data2SC.Zip D:\BdPos\Data2SC
If Exist Temp.Zip D:\BdPos\Pkunzip -o  Temp.Zip D:\BdPos\Temp
If Exist backup.Zip D:\BdPos\Pkunzip -o  backup.Zip Backup
Copy update.Zip M:\_update\.

@If Exist  update.zip  Rename update.zip  Up"%day%_%month%_%year%".zip
@If Exist  Dbfrun.zip  Rename Dbfrun.zip Db"%day%_%month%_%year%".zip
@If Exist  Temp.zip  Rename  Temp.zip Te"%day%_%month%_%year%".zip
@If Exist  backup.zip  Rename  backup.zip ba"%day%_%month%_%year%".zip
@If Exist  Update.Zip Del Update.Zip
@If Exist  Dbfrun.Zip Del Dbfrun.Zip
@If Exist  Data2SC.Zip Del Data2SC.Zip
@If Exist  Temp.Zip Del Temp.Zip
@If Exist  Update.Zip Del Backup.Zip

@Cls
Rem "Copy File Complete ....... Press Anykey To Windows"
Goto END

:NOCOPY4FILE
@Cls
Rem "No File To Copy ....... Press Anykey To Windows"


:END
@Pause 
Exit 







