2

I am trying to make a simple script that writes short statements for me when I use a hotkey such as ^B or ^T. The issue is that when it is typing itself, it will activate another hotkey that then starts straight after it so I am left with a double sentence.

^b::
hello, I am AutoHotKey.

^t::
What can I do for you?

In the above example, the "AutoHotKey" will trigger the second script because of the "t" in it and the fact that it goes faster than the input that the control key is no longer held down.

Is there a way to make one function exclusive so it cannot trigger other functions or will I have to have completely different hotkeys?

4

1 回答 1

7

If you put a $ before the hotkey, it is only activated if pressed

$^b::
Send, hello, I am AutoHotKey.
return

$^t::
Send, What can I do for you?
return
于 2013-10-13T19:31:51.257 回答