Windows batch: sleep [duplicate] Windows batch: sleep [duplicate] windows windows

Windows batch: sleep [duplicate]


You can try

ping -n XXX 127.0.0.1 >nul

where XXX is the number of seconds to wait, plus one.


I don't know why those commands are not working for you, but you can also try timeout

timeout <delay in seconds>


timeout /t 10 /nobreak > NUL

/t specifies the time to wait in seconds

/nobreak won't interrupt the timeout if you press a key (except CTRL-C)

> NUL will suppress the output of the command