batch file - Why is this line printing in CMD when I have told it to cls? -
so want not show pinging, whether or not running. code not doing want is:
@echo off :start ping 188.138.32.53 -n 1 if %errorlevel% == 1 ( goto :fail ) else ( cls echo mtg samp server , running! pause goto :troubleshooting ) :fail cls echo mtg samp server down, please patient... goto :start
it clears screen , says when running, when not running, displays ping status. why this?
as in loop.
the ping needs time detect destination isn't reachable.
see on screen.
after first test, cls
executed , text displayed.
startet test again, ping output.
simply redirect output nul
ping 188.138.32.53 -n 1 > nul 2>nul
Comments
Post a Comment