Replace function of arrow key

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
aquartic

Replace function of arrow key

25 May 2018, 13:55

Hello, I'm brand new to this. I have a weird keyboard and used keytweak to replace the function of the up arrow on my keyboard to be right shift. That works great now, but I'd like to still have the functionality of the up arrow somehow on my keyboard. I wanted to make ctrl+up have the function of the original up arrow key. This is not right, but its what I have so far. Please help!

^Up::
Send, {Up}
return
MaxAstro
Posts: 557
Joined: 05 Oct 2016, 13:00

Re: Replace function of arrow key

25 May 2018, 14:22

What is most like happening is that the up you are sending is triggering your up hotkey. Try adding the $ modifier to the up hotkey.
aquartic

Re: Replace function of arrow key

25 May 2018, 15:16

Could you post an example? I tried and it doesn't seem to work.
MaxAstro
Posts: 557
Joined: 05 Oct 2016, 13:00

Re: Replace function of arrow key

29 May 2018, 09:11

I assume that your code that remaps up to right shift looks something like this:

Code: Select all

Up::
Send {RShift}
return
By default, hotkeys can trigger other hotkeys. So when you do Send {Up}, the "up" that you are sending triggers the "up" hotkey and sends RShift instead. To prevent this, the $ modifier stops a hotkey from being triggered by another hotkey. Modifiers are added at the start of a hotkey, like this:

Code: Select all

$Up::
Send {RShift}
return
If that still doesn't work then there is something else going on and I'm not sure what.

Return to “Ask for Help (v1)”

Who is online

Users browsing this forum: No registered users and 396 guests