Originally posted by lxmxn at 2006-12-2 06:01 PM:
Re 515808051:
I don't know if you've tried it, and I don't know if it works. The above batch script is written according to what you said in the first post. If it doesn't work, you can say which...
Running it, it flashes and nothing happens. Can you explain what it probably means?
If you remove (-n), it shows shutdown...
@echo off
ping www.cn-dos.net (-n) 1 >nul 2>nul || (shutdown -s -t 1800
:KO
ping www.baidu.com (-n) -1 >nul 2>nul && shutdown -a ||goto KO)
goto :eof
=====================================
Don't want to trouble everyone anymore. Thanks again. If you can help further, please do your best.
My idea is as follows
According to the original
@echo off
:start
ping 202.100.199.8
if errorlevel 1 goto end
goto start
:end
shutdown -s -t 600
exit
It's to ping XXX.XXX.XXX.XXX randomly. The main thing is that if it pings through, it doesn't execute the next command.
Whether it pings through or not, it has to execute the next command.
Didn't expect that batch processing is more difficult to learn than Adobe Photoshop...
If it's not possible, it's okay. First, I'll look around for relevant posts to study.
借用 lxmxn 头像
莫见怪