| Main > Software Forum |
| AHK help needed please |
| (1/2) > >> |
| Connorsdad:
I have 8 Ahk.exes loading at startup of windows, each one has a custom loop consisting of: --- Code: ---Loop { Process, Wait, process.exe run blah blah Process,WaitClose, process.exe run blah blah } --- End code --- So Ahk_process1.exe would have: --- Code: ---Loop { Process, Wait, process1.exe run blah blah Process,WaitClose, process1.exe run blah blah } --- End code --- Ahk_process2.exe would have: --- Code: ---Loop { Process, Wait, process2.exe run blah blah Process,WaitClose, process2.exe run blah blah } --- End code --- etc etc etc How do I combine these into one ahk? |
| keilmillerjr:
You can combine them, but autohotkey does not support multi-threading. It runs code one line at at time. |
| Connorsdad:
Only one of the processes will be active at any one time therefore only one loop will be active at any one time. How do I have all the loops in one ahk script? Sent from Amstrad CPC464 |
| Connorsdad:
Sussed it :) Edit: No I haven't :( Sent from Amstrad CPC464 |
| nitz:
--- Quote from: Connorsdad on August 10, 2013, 07:39:48 am ---Only one of the processes will be active at any one time... --- End quote --- If that's the case, I'm thinking something like this could work: --- Code: ---Loop { Process, Wait, process1.exe, 0.1 If (ErrorLevel != 0) { run blah blah Process,WaitClose, process1.exe run blah blah } Process, Wait, process2.exe, 0.1 If (ErrorLevel != 0) { run blah blah Process,WaitClose, process2.exe run blah blah } Process, Wait, process3.exe, 0.1 If (ErrorLevel != 0) { run blah blah Process,WaitClose, process3.exe run blah blah } } --- End code --- |
| Navigation |
| Message Index |
| Next page |