hard inference

Tag: HowTo

How to pause a batchfile (or make a batchfile wait)

by on Jan.28, 2010, under Uncategorized

How to make a batchfile wait or pause? I see many people propose a vbs or c++ program, but this is the easiest way to make a batchfile pause:

Use the TIMEOUT DOS command timeout to make the bacth file wait. For example “TIMEOUT /T 3600″ inserted into your batchfiles will pause for 3600 seconds, or 30 minutes. A user can override this, but if you use the /NOBREAK parameter it will ignore a keypress. If you want it to wait for a keypress indefinately, use the /T -1 setting (wait forever) without the /NOBREAK.

So, to make your batchfile wait for 10 minutes, and ignore keypresses, add in this line:

TIMEOUT /T 600 /NOBREAK

Leave a Comment : more...

Looking for something?

Use the form below to search the site:

Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!

Visit our friends!

A few highly recommended friends...