From 04:00 PM CDT – 08:00 PM CDT (09:00 PM UTC – 01:00 AM UTC) Tuesday, April 16, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

DIAdem

cancel
Showing results for 
Search instead for 
Did you mean: 

How to call a vbs script from another vbs script?

Hi All,
 
        I have written multiple vbs scripts to perform different sub tasks. Now I want to combine them into one single script (which will call other vbs scripts in turns) so that the complete sequence is automated. I tried Call Script1, Call Script1()Script1() etc. But these syntaxes did not work. Kindly let me know how I can call other vbs scripts from a vbs script?
 
With warm regards,
Saurav
0 Kudos
Message 1 of 5
(34,051 Views)
The following worked for me....


Call ScriptStart(autoactpath & "MYSCRIPT.VBS")
BBANACKI
Message 2 of 5
(34,048 Views)
Thanks for the help...
0 Kudos
Message 3 of 5
(34,017 Views)

Hi Murherjee,

The ScriptStart() function is an excellent way to call another VBScript when you don't need to pass it any parameters.  For the case that you want to pass variables to an external function in another VBScript, I'd recommend the ScriptInclude() command.

Brad Turpin
DIAdem Product Support Engineer
National Instruments

Message 4 of 5
(34,001 Views)

Thanks Brad, this also helped me out!  And, funny seeing you here...

0 Kudos
Message 5 of 5
(9,767 Views)