/build/static/layout/Breadcrumb_cap_w.png

VBScript

I never wrote a VBScript before I just need one to run a setup.exe off a server. Any examples would be great.

Thanks

0 Comments   [ + ] Show comments

Answers (1)

Posted by: kkaminsk 20 years ago
9th Degree Black Belt
0
The simple one:

Set shell = CreateObject("WScript.Shell")
file = "\\server\virus\destroyeverything.exe"
shell.Run Chr(34) & file & Chr(34), 1, TRUE


The one with arguements:

Set shell = CreateObject("WScript.Shell")
file = "\\server\virus\destroyeverything.exe"
args = "/Q"
shell.Run Chr(34) & file & Chr(34) & " " & args, 1, TRUE

Heh I forgot to add the tail end... [8D]
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ