Waitfor
Updated: January 21, 2005
Syntax
waitfor [/tTimeoutInSeconds] SignalName
Parameters
Remarks
- Only one instance of waitfor can wait for a given signal on a given computer.
- Signal names are not case-sensitive.
- Signal names cannot exceed 225 characters and cannot contain characters other than a-z, A-Z, 0-9, and ASCII characters in the range of 128-255.
- If you do not use /s, the signal is broadcast to all computers within the same domain as the sending computer. If you use /s, the signal is sent only to the specified computer.
- You can run multiple instances of waitfor on a single computer, but each must wait for a different signal. You can trigger a signal by using the /si command-line option.
- Waitfor runs only on Windows XP and servers running a Windows Server 2003 operating system, but it can send signals to any computer running a Windows operating system.
- Computers can only receive signals if they are in the same domain as the computer sending the signal.
- You can use waitfor when you test software builds. For example, the compiling computer can send out a signal to several computers running waitfor after the compile has completed successfully. On receipt of the signal the batch file that includes waitfor can instruct the computers to immediately start installing software or running tests on the compiled build.
Examples
waitfor /t 10 espresso\build007
To wait forever (the default) or until the "espresso\build007" signal is triggered, type:
waitfor espresso\build007
To trigger the "espresso\build007" signal, type:
waitfor /si espresso\build007
Formatting legend
Format | Meaning |
Italic | Information that the user must supply |
Bold | Elements that the user must type exactly as shown |
Ellipsis (...) | Parameter that can be repeated several times in a command line |
Between brackets ([]) | Optional items |
Between braces ({}); choices separated by pipe (|). Example: {even|odd} | Set of choices from which the user must choose only one |
Courier font | Code or program output |