Setting day,month and year variables in Windows batch

@echo off&SETLOCAL
FOR /f "tokens=1-4 delims=/-. " %%G IN ('date /t') DO (call :FIXDATE %%G %%H %%I %%J)
if "%1:~0,1%" GTR "9" shift
FOR /f "skip=1 tokens=2-4 delims=(-)" %%G IN ('echo.^|date') DO (
    set %%G=%1&set %%H=%2&set %%I=%3)
goto :eof
ENDLOCAL&SET mm=%mm%&SET dd=%dd%&SET yy=%yy%


Popular posts from this blog

How to recalibrate your Samsung Note 4 battery

How to import Tasker projects, profiles, tasks and scenes

How to turn your Windows 7 laptop or dekstop into a WiFi repeater or extender