VBS Script: Wait, Pause, Sleep - SCN
Sleep Method - MSDN - Microsoft
SLEEP SLEEP was included in some of the. Windows Resource Kits. It waits for the specified number of seconds and then exits. SLEEP 10 will delay execution of the next command by 10 seconds. There are lots of SLEEP clones available, including the ones mentioned in the. UNIX Ports paragraph at the end of this page. TIMEOUT was included in some of the. Windows Resource Kits, but is now a standard command in Windows 7 and 8 (not sure about Vista). Vbs" ECHO eep 1 1000 CSCRIPT /NoLogo "eep. vbs" DEL "eep. vbs" Or if you want to allow the user to skip the delay: @ECHO OFF REM 1 is the number of seconds for the delay, as specified on the command line "eep. NETSH is native in Windows XP Professional and later versions. Unfortunately however, this trick will only work in Windows XP/Server 2003. CHOICE t Uses CHOICE to wait for a specified number of seconds.
By using REM before the CHOICE command, the standard input to CHOICE is blocked, so the only "way out" for CHOICE is the time-out specified by the /T parameter. The idea was borrowed from Laurence Soucy, I added the /C parameter to make it language independent.
Vbscript wait statement
If specified (-w switch PING will wait for a number of milliseconds between two pings before giving a time-out. PING -n 1 -w 60000 NUL will delay execution of the next command 60 seconds, provided is not a valid IP address (I previously used -n 60 -w 1000 which should theoretically result in.
Written by: Island Roots
2,7 / 5 stars