Welcome, Guest. Please login or register.
Did you miss your activation email?
May 27, 2012, 04:50:16 AM

Login with username, password and session length
Search:     Advanced search
* Home Help Search Calendar Links Login Register
+  Machsupport Forum
|-+  Mach Discussion
| |-+  VB and the development of wizards
| | |-+  Wait until external application ends...
Pages: 1   Go Down
Print
Author Topic: Wait until external application ends...  (Read 408 times)
0 Members and 1 Guest are viewing this topic.
giannis121
Active Member

Offline Offline

Posts: 128


View Profile
« on: November 12, 2010, 04:51:54 AM »

I'm using a button to call an external application:
Shell ("c:\myapplication.exe")

Inside the same button i want to load a file after "myapplication" file is closed.
LoadFile("c:\myfile.txt") 

So, i need something like "~wait for myapplication to close" between these commands:
Shell ("c:\myapplication.exe")
"Wait for myapplication to close"
LoadFile("c:\myfile.txt")

How can i do that?

Logged
giannis121
Active Member

Offline Offline

Posts: 128


View Profile
« Reply #1 on: November 20, 2010, 12:15:15 PM »

The problem was solved as following:

I created a button which has VB script:
LoadFile("c:\myfile.txt")
While IsLoading()
Sleep 100
Wend


This button has enabled a HOTKEY (for example key "0").
So when my application finishes, focuses on Mach application
and sends a keystroke "0" (the HotKey).

2-3 days of searching and i didn't find any other solution.
Still if you have any idea of controlling it through Mach,
please share.

Giannis
Logged
Pages: 1   Go Up
Print
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.16 | SMF © 2011, Simple Machines Valid XHTML 1.0! Valid CSS!