computing
  • 0

Solved How Do I Run a Batch File Every 20 Mins Without Task Schedule

  • 0

I need to run a batch file every 20mins on strip down WindowsNT machine that doesnt have Task Scheduler on it. Is there a way to do it?

Share

1 Answer

  1. Yeah, I know. If you had done it yourself, it’d be sane looking. Like this:

    Const sleepTime = 20 * 60 * 60000
    Set shell = CreateObject("Wscript.Shell")
    Do While True
      WScript.Sleep sleepTime
      WshShell.Popup "PLEASE CHECK ALL GET ARE INTACT. IF MISSING REPORT IMMEDIATLY. THIS MESSAGE WILL SELF DISTRUCT IN 10s'." ,10 ,"CHECK GET Click OK!", 0
    Loop

    Note: I’m not sure which version of the VBScript engine your WinNT box has. For a while, the engines were released with Internet Explorer. It wasn’t until Win2K that VBScripts were guaranteed to actually run, and WScript.Sleep wasn’t included until version 2.0.

    How To Ask Questions The Smart Way

    • 0