[SOLVED] Using CapsLock (or any other key) as temporary modifier (only when it's pressed)

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
babzezz
Posts: 9
Joined: 06 Jan 2017, 19:31

[SOLVED] Using CapsLock (or any other key) as temporary modifier (only when it's pressed)

23 Jan 2017, 11:25

So I want to use the CapsLock key as a temporary insert key, meaning I want the insert mode functionality (overwrite) only when I have CapsLock is pressed.

I have no idea what this type of script is called and my searches describing this problem didn't yield any useful results. I guess this is a type of question that is asked regularly but I'm sorry, I could find no solution other than to ask here.

Thanks for the help in advance.
babzezz
Posts: 9
Joined: 06 Jan 2017, 19:31

Re: [SOLVED] Using CapsLock (or any other key) as temporary modifier (only when it's pressed)

23 Jan 2017, 15:18

Okay so this has helped me to achieve it:

Code: Select all

SetCapsLockState, alwaysoff
return

$CapsLock::
Send {Ins}
KeyWait, CapsLock
Send {Ins}
return

Return to “Ask for Help (v1)”

Who is online

Users browsing this forum: Google [Bot], Kodakku and 393 guests