Hi,
I just saw this:
Sleep Method
See Also
Running Your Scripts | WScript Object
Suspends script execution for a specified length of time, then continues execution.
object.Sleep(intTime)
Arguments
object
WScript object.
intTime
Integer value indicating the interval (in milliseconds) you want the script process to be inactive.
Remarks
The thread running the script is suspended, releasing its CPU utilization. Execution resumes as soon as the interval expires. Using the Sleep method can be useful when you are running asynchronous operations, multiple processes, or if your script includes code triggered by an event. To be triggered by an event, a script must be continually active (a script that has finished executing will certainly not detect an event). Events handled by the script will still be executed during a sleep.
Note Passing the Sleep method a 0 or –1 does not cause the script to suspend indefinitely.
...and thought: may be we should better use this instead of MSch Wait? Or will it be the same, regarding to the system resources?
Thank you!
Olga.
Can Shell Sleep method help?
Moderators: Dorian (MJT support), JRL
- Marcus Tettmar
- Site Admin
- Posts: 7395
- Joined: Thu Sep 19, 2002 3:00 pm
- Location: Dorset, UK
- Contact:
Wait also calls the Win32 API sleep function and therefore does exactly the same as WScript's sleep function. In any case you cannot use WScript's sleep function in Macro Scheduler because, well, it belongs to WScript anyway. WScript is the Windows Scripting Host. So it is irrelevant to Macro Scheduler. Macro Scheduler's Wait does the same thing.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar
Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?