Solved

Batch file: Run each 5 minutes

Posted on 2011-09-18
3
387 Views
Last Modified: 2012-05-12
I want to write a batch file to run each 5 minutes
0
Comment
Question by:egovernment
  • 2
3 Comments
 
LVL 6

Expert Comment

by:KOTiS
ID: 36556033
If you are running MS-DOS under Windows the you can create a schedule to run the batch file. If your only OS is MS-DOS then there are some resident programs. What is your OS?
0
 
LVL 43

Accepted Solution

by:
Steve Knight earned 500 total points
ID: 36556074
Yes you can either schedule it using task scheduler like has been said, or you can run one batch that pauses for 5 minutes (ish), either using a third party util, or a "PING" command, e.g.:

@echo off
:loop
echo Do the things you want here.  It is %time%
for /l %%a in (5,-1,1) do (
  echo Waiting for %%a for minutes....
  ping -n 61 -w 1000 127.0.0.1 >NUL 2>&1
)
echo Running again now
goto :loop
And call that "Yourbatch.cmd" or whatever.

Steve
0
 
LVL 43

Expert Comment

by:Steve Knight
ID: 36934968
Thanks.  What did you end up doing?
0

Featured Post

U.S. Department of Agriculture and Acronis Access

With the new era of mobile computing, smartphones and tablets, wireless communications and cloud services, the USDA sought to take advantage of a mobilized workforce and the blurring lines between personal and corporate computing resources.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Being a system administrator some time we require to do things remotely, one of them is installing software. Here I am going to tell you how to install software through wmic (Windows management instrument console). I am not at all saying that this i…
Introduction: Recently, I got a requirement to zip all files individually with batch file script in Windows OS. I don't know much about scripting, but I searched Google and found a lot of examples and websites to complete my task. Finally, I was ab…
This Micro Tutorial will teach you how to censor certain areas of your screen. The example in this video will show a little boy's face being blurred. This will be demonstrated using Adobe Premiere Pro CS6.
This Micro Tutorial will give you a basic overview how to record your screen with Microsoft Expression Encoder. This program is still free and open for the public to download. This will be demonstrated using Microsoft Expression Encoder 4.

832 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question