How can Win+P be disabled in Windows 7?
I have already disabled the Win-key hotkeys with NoWinKeys
as well as the Win+Arrow keys in the DWM. However Win+P, the hotkey for the projector settings (which I don’t use anyway because I have a desktop with only one monitor, not a laptop) seems to be immune to that setting. Every other Win-key hotkey is disabled (including, to my chagrin, Win+Tab), but Win+P remains resolute to ruin my day by preventing me from mapping it to a command prompt. (To be accurate, Win+U is also adamantly reserved for the accessibility options, regardless of whether or not you enable or use them.)
Since I have used NoWinKeys
, I suspected that it must not be getting hooked by Explorer, but rather some other component (a driver?) like the Mobility Center (which also hooks Win+X), however again, I am not using a laptop. (I do recall at one point in the past using some hack to enable the Mobility Center on a desktop, but I think that was in a previous installation because that key doesn’t exist now.)
Does anyone know how to disable Win+P or how to figure out where it is being hooked in order to stop it?
(Yes, there are two questions on SU that mention Win+P, but neither has a solution to this.)
Solution 1:
You can disable Win-P with a simple AutoHotkey script, that consists of four characters:
#p::
stands for windows key
- p is for - well - p
- The :: is for "hotkey"
If you want to run the command prompt with Win-P the code will look like this:
#InstallKeybdHook ; to make extra sure the keys are caught by AutoHotkey
#p::run cmd.exe
I've tested both and they work for me under Windows 7 Ultimate. If you don't want to install AutoHotkey, download the zip, create the script in an editor and save it with the .ahk ending. If need be, it can be compiled into an .exe.
I have actually created a pretty nice post about disabling hotkeys with AutoHotkey.
Using AutoHotkey, you can customize and remap pretty much any key or hotkey on your keyboard.
But essentially I agree: any decent program should come with a built-in functionality to customize or disable hotkeys for certain functions.
Solution 2:
This is a rather old discussion but you can just rename the program the win+p calls "DisplaySwitch.exe" (found in the system folder) to something else. The fact would then remain the key is still there but attempts to summon a program that has a new name. To rename/move/delete the file you will need to also claim ownership which can be done in the properties. I am certain of how that would effect assignment of win+p to other tasks. This solution will not require any script or 3rd party software.