Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Starting 3 Applications. How do you end app 2 & 3 when 1 Closes 1

Status
Not open for further replies.

moe44

IS-IT--Management
Jan 13, 2002
1
US
I use WSHShell.Run to start notepad.exe, calc.exe and write.exe. How do I set calc.exe and write.exe to close when notepad.exe ends.

Thanks
 
This sounds ugly, but it is all I can think of.


First get the most recent version of the scripting software you can. 5.6 now, I think?

Then get the most recent Help file so you can look into the details of the Methods needed.


Use the Run method to start calc and write, without waiting.

The use Run to start notepad in "wait on return" mode (use the third parameter to Run: True to wait).

When notepad completes, use AppActivate and SendKeys to shut the other programs down.


Told you it was ugly!

Anybody else?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top