I commented out the 3 lines because none of them work.
I am dynamically creating hotkeys from config data using HotKey. The hotkey will call a function. When the hotkey is triggered, I want additional data to be sent to the function.
Code: Select all
#Requires AutoHotkey v2.0
#Warn Unreachable, off
#SingleInstance Force
data := ["^!+a", "^!+b", "^!+c"]
for i, v in data
{
; HotKey v, (ThisHotKey) => dingo(i, v)
; HotKey v, (ThisHotKey) => dingo.bind(i, v)
; HotKey v, dingo.bind(i, v)
}
dingo(index, data)
{
msgbox index " " data
return
}