HotKeySet ( "key" [, "function"] )
No way I can send a parameter to the function?
I am setting a dozen of hotkeys, and all I need is to call the same function with diferent parameters
so at this moment my script, looks dumb, like this:
HotKeySet("^!u", "Func1")
HotKeySet("^!o", "Func2")
HotKeySet("^!i", "Func3")
...
While 1
Sleep(100)
WEnd
Func SendUnicode($text)
$SaveClip = ClipGet()
ClipPut($text)
Send("^v")
ClipPut($SaveClip)
EndFunc
Func Func1()
SendUnicode("ü")
EndFunc
Func Func2()
SendUnicode("ö")
EndFunc
Func Func3()
SendUnicode("ï")
EndFunc
...
would be much better to define keys this way:
HotKeySet("^!u", "SendUnicode(1)")
HotKeySet("^!u", "SendUnicode(2)")
HotKeySet("^!u", "SendUnicode(3)")
....
and then In the SendUnicode function i will implement a "case" to send the desired text depending on the code. That would erase the dumb copy-paste functions Func1, Func2, Func3 ... etc