9

Is there a way to remap the Windows key to the CTRL key? So whether I press CTRL or the Windows key both will trigger CTRL key code.

Edit:
It looks like if I use AutoHotKey I can use the following script:

LWin::ctrl

This actually is working for me but it requires me to install a separate program and create a hot key script.

The purpose of this is How to use an Apple keyboard with Windows remapping the Windows key to simulate the Apple Command key.

3 Answers 3

5

AutoHotKey is unnecessary.

Windows does keymaps via Registry you can find here:

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout]
"Scancode Map"

Also, the Left and Right Win and CTRL keys each have their own values. If you want both to map to CTRL, you'll have to make sure to specify both in the map:

Right Windows to Right CTRL:

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout]
"Scancode Map"=hex:00,00,00,00,00,00,00,00,02,00,00,00,1d,e0,5c,e0,00,00,00,00

Left Windows to Left CTRL:

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout]
"Scancode Map"=hex:00,00,00,00,00,00,00,00,02,00,00,00,1d,00,5b,e0,00,00,00,00

Both Windows keys:

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout]
"Scancode Map"=hex:00,00,00,00,00,00,00,00,03,00,00,00,1d,00,5b,e0,1d,e0,5c,e0,\
  00,00,00,00

Backup your Registry, and merge the appropriate entries. Manual entry will work, but the easiest way is to create a text file with .reg extension and insert one of the above entry's like so:

Example .reg file:

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout]
"Scancode Map"=hex:00,00,00,00,00,00,00,00,02,00,00,00,1d,00,5b,e0,00,00,00,00

Double click it to active it. You can then restart your computer, and you're good to go. If a Scancode Map entry is already there, this will not work, and you will need to modify it or delete it first.


I've personally used the SharpKeys utility to map the CTRL key on my very old keyboard to the Windows key (which is lacks).

2
  • This method can also be used for the reverse: use Ctrl as Windows key in those old keyboards that don’t have Windows Key (IBM model M, for instance).
    – Chungalin
    Commented Mar 17 at 14:04
  • @Chungalin this method works for any key mappings you want. The SharpKeys utility is very flexible like that, and you can read/store/restore the settings it applies as you please. Commented Mar 18 at 15:31
4

I use Sharpkeys which figures out the Windows registry mapping for you and lets you pick the key combinations from the keyboard.

I've been using this for a few weeks and it's exactly what I needed.

0

I've used PowerToys to remap. I've used it to interchange LCtrl and CapsLock for a few months and it's worked well. You can even do complex keybindings although I haven't tried it.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .