2/3 How to check multiple processes?

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
Awannaknow
Posts: 78
Joined: 01 Oct 2013, 08:07

2/3 How to check multiple processes?

28 Mar 2017, 08:31

This thread is a continuation of this thread:
1/3 How to Check opened PID With Timer and Array?
I can't even formulate my problem clearly enough for you to understand what I need to solve . . .
Simply put:
Modified shortcuts includes the script in their path.
On shortcut opening (double clicking on any modified ones)
The script launch itself and launches what the unmodified normal shortcut should have launched, call it "A".
And additionally check "A" PID until it is closed.
I did it with process waitclose, which works only for one process or file, then I did it with a SetTimer and Array() and Hotkey.
it works, but it was just to test it.
I need it to work with as described above "Modified shortcuts includes the script in their path.
On shortcut opening (double clicking on any modified ones) . . ."
This works for one process or file.
But when the script is launched, trying to launch additional modified shortcut doesn't works.
Here what I could code:
1- with hotkey: working but it is not what I need: I need it without hotkey to launch it, but with shortcut like I show below in code # 2.
2- a poor attempt to make it working from double click on modifieds shortcuts. This is what I need working.
I suppose it has to do with thread problem, but I cannot find how to do it correctly, although I tried and tried.
Maybe an example could help me a lot or indications on how to solve it.
Pseudo code could be:
Open a file with a shortcut
check if the file is opened
open other file(s)
check all opened files
when one file close don't check it anymore
same for each file
when no more file to check, close the script

Although the script above is working, I need to continue as it is not the solution I need, so I decided to make a continuation thread here:
3/3 How can I do this?:

Return to “Ask for Help (v1)”

Who is online

Users browsing this forum: filipemb, Google [Bot], Rohwedder, slowwd and 219 guests