Eran
Fri Sep 10 01:44:45 CDT 2004
Torgeir, reading the script and then executing global won't do the trick?
"Torgeir Bakken (MVP)" <Torgeir.Bakken-spam@hydro.com> wrote in message
news:%23NoM5rrlEHA.536@TK2MSFTNGP11.phx.gbl...
> Jim Bayers wrote:
>
>> I run a bunch of scripts on my server. Each is scheduled individually
>> with the sceduling service.
>>
>> I'm thinking of writing one script that calls each script in turn. That
>> way, I will only have one entry in scheduler.
>>
>> Is this possible?
> Hi
>
> '--------------------8<----------------------
> Set oShell = CreateObject("WScript.Shell")
>
> ' If you want them to run in parallel:
> oShell.Run "wscript.exe c:\scripts\scr1.vbs", 1, False
> oShell.Run "wscript.exe c:\scripts\scr2.vbs", 1, False
> oShell.Run "wscript.exe c:\scripts\scr3.vbs", 1, False
>
> ' If you want script 1 to be finished before script 2 is started:
> oShell.Run "wscript.exe c:\scripts\scr1.vbs", 1, True
> oShell.Run "wscript.exe c:\scripts\scr2.vbs", 1, True
> oShell.Run "wscript.exe c:\scripts\scr3.vbs", 1, True
> '--------------------8<----------------------
>
>
> Note that
> oShell.Run "wscript.exe c:\scripts\scr1.vbs"
>
> Is the same as
> oShell.Run "wscript.exe c:\scripts\scr1.vbs", 1, False
>
> because ", 1, False" is the default
>
>
>
> WSH 5.6 documentation (local help file) can be downloaded
> from here if you haven't got it already:
>
>
http://msdn.microsoft.com/downloads/list/webdev.asp
>
>
>
>
> --
> torgeir, Microsoft MVP Scripting and WMI, Porsgrunn Norway
> Administration scripting examples and an ONLINE version of
> the 1328 page Scripting Guide:
>
http://www.microsoft.com/technet/scriptcenter/default.mspx