unexpected behaviour of a function call in a one-line hotkey
Posted: 17 Aug 2017, 12:26
The following single-line script unexpectedly runs:Also, if I were to define a function with the name, the function would not get called. Please see https://autohotkey.com/boards/viewtopic ... 03#p165103.
In the thread forum user Helgef identified the problem as the line being interpreted as a remapping F12::sca. sca is the 9-key in the top row of the keyboard.
This is in contradiction to the documentation: https://autohotkey.com/docs/Hotkeys.htm#Intro
I tested on Win10 64-bit with AHK v1.1.26.01 64-bit.
Code: Select all
F12::scaHELLOWORLD() ; no function defined with this name
In the thread forum user Helgef identified the problem as the line being interpreted as a remapping F12::sca. sca is the 9-key in the top row of the keyboard.
This is in contradiction to the documentation: https://autohotkey.com/docs/Hotkeys.htm#Intro
After about two days no more responses were posted in the thread, so I think this might be an unknown bug.Hotkeys wrote:However, if a hotkey needs to execute only a single line, that line can be listed to the right of the double-colon.
I tested on Win10 64-bit with AHK v1.1.26.01 64-bit.