Код:
@echo off
chcp 1251>nul
set CurDate=%date:~6,4%%date:~3,2%%date:~0,2%
set CurTime_1=%time:~0,2%%time:~3,2%%time:~6,2%
set /a CurTime_2=%CurTime_1%
if not "%CurTime_2%"=="%CurTime_1%" (
set CurTime=0%CurTime_2%
) else (
set CurTime=%CurTime_1%
)
>nul copy "d:\all\doc.csv" "d:\all\пример_%CurDate%_%CurTime%.csv"
echo Done!
pause>nul
exit /b