RAlt and comma combo

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
User avatar
jackcalico
Posts: 6
Joined: 18 Sep 2021, 08:42

RAlt and comma combo

Post by jackcalico » 18 Sep 2021, 08:51

First time for me tinkering with AHK and I am having some difficulties. This is the scenario:

I am trying to create a script so that when Right Alt and Comma are pressed it returns <

I am using an ANSI keyboard (RK61) on Windows 10 with Spanish (Spain) as the keyboard layout (via Windows language settings).

If I try

Code: Select all

RAlt,::<
it doesn't work (Invalid hotkey).
If I try

Code: Select all

<^>!,::<
it runs the script but pressing Right Alt and Comma outputs nothing.

Any ideas?
User avatar
mikeyww
Posts: 26885
Joined: 09 Sep 2014, 18:38

Re: RAlt and comma combo

Post by mikeyww » 18 Sep 2021, 08:59

Code: Select all

>!,::Send <
User avatar
jackcalico
Posts: 6
Joined: 18 Sep 2021, 08:42

Re: RAlt and comma combo

Post by jackcalico » 18 Sep 2021, 09:11

mikeyww wrote:
18 Sep 2021, 08:59

Code: Select all

>!,::Send <
Thanks, since I am using the Spanish keyboard layout I had to modify your script to

Code: Select all

<^>!,::Send <
instead and that works!!

Thanks a bunch!
gregster
Posts: 9002
Joined: 30 Sep 2013, 06:48

Re: RAlt and comma combo

Post by gregster » 18 Sep 2021, 18:34

Just to clarify: You have an AltGr key, not a RAlt key (like, for example on the regular US layout). These are different key types.
Post Reply

Return to “Ask for Help (v1)”