[basic question] check for specific window focus before handing a keypress Topic is solved

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
Wpq
Posts: 14
Joined: 02 Mar 2021, 04:15
Location: France

[basic question] check for specific window focus before handing a keypress

Post by Wpq » 22 Nov 2021, 05:33

I am trying to bind the "mute" button of my keyboard to the mute function of Zoom (Alt+A), when the Zoom meeting window has focus:

Code: Select all

if WinActive("Zoom Meeting")
	Volume_Mute::Send !a
Unfortunately, the code above always sends Alt+A, no matter the window (and, when the Zoom meeting is focused, it is indeed muted).

Is WinActive the correct condition?


Post Reply

Return to “Ask for Help (v1)”