2 different hotkey's , one for each script, but only one works

Get help with using AutoHotkey (v1.1 and older) and its commands and hotkeys
User avatar
Frosti
Posts: 426
Joined: 27 Oct 2017, 14:30
Contact:

2 different hotkey's , one for each script, but only one works

24 May 2018, 13:37

one script contains the following hotkey:

Code: Select all

		LControl & ü::																							
		ListLines
		return
the other script uses that combination:

Code: Select all

^!ü::ListVars
If I press LControl + LALT + ü - only Hotkey from file 1 works.
I found following solution that works:

Code: Select all

$^!ü::ListVars
It makes me very uneasy that I just do not understand why the first version of File 2 wan't works, but the last one does it.
Please save my evening and my sleep!
User avatar
TLM
Posts: 1608
Joined: 01 Oct 2013, 07:52
Contact:

Re: 2 different hotkey's , one for each script, but only one works

24 May 2018, 17:02

The Manual wrote:$ The $ prefix forces the keyboard hook to be used to implement this hotkey, which as a side-effect prevents the Send command from triggering it. The $ prefix is equivalent to having specified #UseHook somewhere above the definition of this hotkey.
User avatar
Frosti
Posts: 426
Joined: 27 Oct 2017, 14:30
Contact:

Re: 2 different hotkey's , one for each script, but only one works

24 May 2018, 18:16

Thanks, I see now that I did not recognize a simple logical connection. My two hotkeys containing the combination LControl and the ü key, the hotkey is taken in the first that met first all conditions. The entry was successful and thus the two successful entry keys are removed. Do you know if the Alt key in my example, if I had another hotkey such as Alt + 4 (I still have my fingers on Ctrl + Alt + ü) and after triggering Ctrl + ü , and then I addionally hold down key 4 the Hotkey Alt + 4 is triggered?
Complicated explained. And I also do not know why this would be useful. Perhaps it helps me to understand how hot keys works.
Do you understand my question?

Return to “Ask for Help (v1)”

Who is online

Users browsing this forum: Google [Bot], wilkster and 339 guests