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

x
  • 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
</script>

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

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


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..
0

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