Go Premium for a chance to win a PS4. Enter to Win

  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 302
  • Last Modified:

wsh.run: executing multiple commands in order

I have a website that a user can go to install software on their computer. They select a piece of software, and then click on submit. It executes an MSI script on a server that we have.

What I would like to do is allow them to select multiple pieces of software then install them in an order when the one finishes, the other picks up. Here is the command I use to execute the application:

<script language=VBscript>
Set wsh3 = createObject("WScript.Shell")    
'Comstring = path to msi script
wsh3.run comstring
'msgbox comstring

Is there a way to accomplish this. I haven't even attempted, thinking that it will not wait for the first piece to finish.
1 Solution
wsh3.run comstring, 1, True

The last parameter causes it to wait for the executed program to finish before continuing.
tchousAuthor Commented:

That seems to work. Is there anyway to get the normal text on  the page to load first, then run the vbscript job. The screen turns white until the jobs are finished..

Featured Post

How to Use the Help Bell

Need to boost the visibility of your question for solutions? Use the Experts Exchange Help Bell to confirm priority levels and contact subject-matter experts for question attention.  Check out this how-to article for more information.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now