I'm trying to start and .exe at a certain time frame, but despite not matching GEQ yet (e.g. 20:55), it still goes to the :run label.
I've also tried only EQU, but here, despite matching the time, it doesn't goto :run. Only if i start the batch at the exact %time%, it works, but obviously that's missing the whole point.
Whats wrong here?
@ECHO OFF
SET hour=%time:~0,5%
echo It is %hour%
:check
echo.
echo %time:~0,5%
echo checking
timeout /t 60
IF %hour% GEQ 21:00 IF %hour% LEQ 22:00 (goto :run) else (goto :check)
:run
echo running
start chrome.exe
pause