I have 2 repeating actions that I want constantly waiting. Specifically, there are a couple of windows that, when they appear, I want AutoHotkey to perform an action on. For example, I want to move and resize the window with title "Window 1", and send a y keypress to "Window 2". So I have this:
win1.ahk
While, 1
{
WinWaitActive, Window 1
WinMove, Window 1, , 100, 100, 800, 600
}
win2.ahk
While, 1
{
WinWaitActive, Window 2
send y
}
My question is whether it is possible to put multiple such actions in the same AutoHotkey script. If I have 30 different windows that I want to wait on, do I need 30 individual .ahk scripts with this format, or is it possible to register several actions all in a single script?