disable Win key +x hotkeys Topic is solved

Ask gaming related questions
Posts: 4
Joined: 28 Jun 2016, 03:09

disable Win key +x hotkeys

01 Sep 2017, 12:14


I would like some help on this.
I have tried editing registry entries to set No WIN + x hotkey functionality.
It seems this does not work on X64 version and looked everywhere and tried
some of the Autohotkey codes but to no success.

As the subject says I am trying to disable the win key hotkey functions.
Ie, I do not want to run ANY Win7 ( X64 ) WIN hotkey actions.
WIN + L does not lock the computer
WIN + P does not ask me to choose a display or whatever it asks me for
WIN+F to launch Search
and so on.

I am trying to do this because I am learning LaTex and I want to use
Autohotkey to make the Latex commands easier. There are already
ctl and alt hotkeys so a new set (user set) of hotkeys
would be logical to begin with a #.

I want to use things like

SendMode Play
SetKeyDelay, 10, 10, Event

#if GetKeyState("LWin", "P")
p::Sendevent {Numpad4}
x::Sendevent {Numpad4}
l::Sendevent {Numpad4}
shift & l::Sendevent {Numpad4}
shift & f::Sendevent {Numpad4}

without invoking the system actions listed above.

Now you can see why I want to disable WIN key functionality only and not
to completely disable the key.

I hope someone would be able to help me.
Posts: 4
Joined: 28 Jun 2016, 03:09

Re: disable Win key +x hotkeys (Solved)  Topic is solved

01 Sep 2017, 21:19

Solved to my satisfaction.

Only by chance I stumbled on to a solution if you can call it a solution.
Really it is just a warning to be mindful of a trap.

In the hope that this helps someone spending hours on end trying to understand why it does not work,
I will tell you vaguely how I got it to work.

Why vaguely? one of the registry edits may be unnecessary.

First off my OS is Win7 X64.

(1) I did the register edits.

I looked at http://www.intowindows.com/how-to-disab ... dows-78-1/
and many similar pages.

Like it said on AUTOHOTKEY online pages, (1) won't disable WIN+L and WIN+U.
With (1) my script will always run the system Lock and Select Monitor Windows default actions.

But this is a better link I think.
see here http://www.geoffchappell.com/notes/wind ... otkeys.htm
Because it had Disable All and Disable Selectively methods
For this I set DisabledHotkeys to "PU" in the hope that it would disable WIN+P and WIN+U

Note: I don't know if Disabe Selectively helped though but it did not hurt so I did not undo the edit.

(2) This is the important part: When windows starts DO NOT be tempted to press WIN+P or WIN+U to check
whether your edits have worked.

If you do you might find that these key combos are permanently assigned to Windows Default actions until next reboot.
This is the trap that I fell into time after time wasting a lot of hours and frustration.

Load/run your AutoHotKey script first!
My test script was
if not A_IsAdmin
Run *RunAs "%A_ScriptFullPath%" ; Requires v1.0.92.01+

SendMode Play
SetKeyDelay, 20, 20, Event ; Note that both 0 and -1 are the same in SendPlay mode.

; Put script for the game here. something like

#P::Sendevent {Numpad4} ; this sends 4 to the active window and not Lock the computer default action

#U::Sendevent {Numpad4} ; this sends 4 to the active window and not bring up select monitor default action


Only then the Windows default action for WIN+L and WIN+U key combo seems to gets overridden by the script.

Hope this little thing solves helps you in some way.
Posts: 266
Joined: 09 Aug 2015, 01:34

Re: disable Win key +x hotkeys

03 Sep 2017, 00:08

i have a script that disable win key under games ( full screen) and remaps it to f13 so you can even use it as en extra button in the game.

it works perfect and disable win+p and win+u as well
this is just the disalbe winkey part

hotkey, *LWin, Blank, On
hotkey, *RWin, Blank, On

Send {Blind}{f13}

Return to “Gaming”

Who is online

Users browsing this forum: bushez, Google [Bot], Rohwedder and 9 guests