Prevent a program from intercepting a hotkey

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
Lem2001
Posts: 127
Joined: 27 Jun 2017, 17:59

Prevent a program from intercepting a hotkey

12 Nov 2018, 22:40

I have a hotkey (Ctrl+Alt+L) that I have assigned using the option settings of a particular program. It performs a certain function regardless of which program has focus at the time (so it functions system-wide) but the hotkey itself was set within the program, and not defined by me in AutoHotkey.

It works fine, but the Windows Magnifier app also uses that same hotkey, and it takes over and interferes with the action of the first program whenever Magnifier is active.

How can I make the hotkey continue to behave as normal regardless of whether Magnifier is running or not?

I have been able to use IfWinExist to disable the hotkey when Magnifier is active, but while that does prevent Magnfier from performing its own action in response to the hotkey, it still doesn't perform the same function as when Magnifier is not running (which is what I would like it to do).

I just want Magnifier to leave that hotkey alone and let it do whatever its assigned to do elsewhere, rather than me having to specifying a particular action for the hotkey that should be used when Magnifier is active. So, I'm looking for a sort of hotkey "pass-through".

I can't / don't want to manually assign a function to that hotkey when Magnify is active because:

1. The function that the hotkey performs is not something that could be activated or recreated in AHK, and
2. I don't want to 'hard-code' a specific function to that hotkey just for Magnifier (because things get messy and confusing if the global hotkey is ever changed in future).

Thanks
colt
Posts: 291
Joined: 04 Aug 2014, 23:12
Location: Portland Oregon

Re: Prevent a program from intercepting a hotkey

14 Nov 2018, 09:28

Magnifier does not interfere with (Ctrl+Alt+L) on my machine. Maybe there is something else going on in your script. Create a new script with only (Ctrl+Alt+L) in it to see if that makes a difference.
Lem2001
Posts: 127
Joined: 27 Jun 2017, 17:59

Re: Prevent a program from intercepting a hotkey

17 Nov 2018, 01:32

By "interfere" I mean that it's a hard-coded Magnify hotkey.

Magnify does not provide a user option to modify the hotkeys for Full Scree, Lens and Docked. Therefore, pressing Ctrl+Alt+L when Magnifier is active always activates Magnify's 'Lens' option, even though I don't want it to.

Image
KeyC0de
Posts: 2
Joined: 05 Mar 2020, 06:18

Re: Prevent a program from intercepting a hotkey

09 Apr 2020, 06:40

I am also interested in this. Is there a way to prevent a program from consuming inputs from inside autohotkey?
gregster
Posts: 9067
Joined: 30 Sep 2013, 06:48

Re: Prevent a program from intercepting a hotkey

09 Apr 2020, 06:42

Try to run your script 'as admin'.

Return to “Ask for Help (v1)”

Who is online

Users browsing this forum: Bing [Bot], mikeyww, ntepa and 149 guests