I have previously used Process, Exist, Name of exe to determine the PID, but as this is a VST, hence being hosted by the DAW.exe, I'm currently unable to stop hotkeys triggering outside of the window when it's in focus.
I'm using the below function to determine this, so I can call it from other functions and scripts within the set.
Code: Select all
GetLocation()
{
IfWinActive, StylusRMX
{
WinWaitActive, StylusRMX
blnResult:=1
}
Else
{
blnResult:=0
}
Return blnResult
}
I've looked at WinExist, WinWait, IfWinActive etc etc, but it's becoming a bit of a grey area for me. So, what's the best approach in making these scripts only active when this plugin is in focus? THX for any help Steve.