07-23-2023, 09:53 AM
for /F "tokens=1-4 delims=/ " %%i in ('date /t') do (
set Day=%%k
set Month=%%j
set Year=%%l
set DATE=%%k/%%j/%%l)
I am try to get the date into the above variables in a batch script, but currently the date comes out as
2011/04/
Any suggestions on how to fix this?
set Day=%%k
set Month=%%j
set Year=%%l
set DATE=%%k/%%j/%%l)
I am try to get the date into the above variables in a batch script, but currently the date comes out as
2011/04/
Any suggestions on how to fix this?