Windows XP Tips, Tricks, Settings and more ...

MCSE Training Courses / Cisco Training Courses

Home/   Desktop/   Email/   Internet Explorer/   MSDos/   Networking/   Printer/   Registry/   
Training/   Windows 2000/   Windows 98/   Windows ME/   Windows NT 4.0/   Windows Vista/   Windows XP/

Batch file SLEEP Command

In Category: MSDos

1. Go to the Microsoft Windows Server 2003 download section at
downloads/tools/default.mspx. Or, if that link does not work, visit and search for "Windows 2003". Once there, choose the "Downloads -> Tools" link.

2. Select the link "Windows Server 2003 Resource Kit Tools".

3. Click the "Download" link. Choose to register or not, depending on your choice, and follow the on-screen instructions to download and install the product. The default install directory is "C:\Program Files\Windows Resource Kits\Tools\".

Once the Windows 2003 Resource Kit is installed, you may need to reboot your machine for the directory "C:\Program Files\Windows Resource Kits\Tools\" to be added to your path.

Now that the sleep command is available, to see the online help, enter the following DOS command:

C:\>sleep /?

Or, just issue the command:

C:\>sleep N

Replace N with the number of seconds for batch file to 'sleep'. For example, a batch file can wait 5 seconds before continuing by issuing this command:

C:\>sleep 5

If you need to wait just a few milliseconds, issue this command:

C:\>sleep -m N

So, to sleep half a second:

C:\>sleep -m 500

Although this command supports a 'precise' millisecond sleep, I would not recommend it for real-time processing!


FREE Learn English - Food
Speak English - Drinks
Windows Training

Top Articles:

Accounting Software Review
Dedicated Servers
Backup Software
Unix Training
Role of the Helpdesk
Distance Learning

Top Training:

Office 2010 Training
C# Training
Windows 7 Training
Sage Line 50 Training
A+ Training
CCNA Training

© 2007-2011 - RCS Limited. Terms & Conditions