This is either "wish I could do that" or "how do I do that". I currently am interested in having my script take a variable containing the name of an AutoHotkey function I've written, or perhaps containing the name of an ordinary program code label, and execute that function or executing GOSUB or GOTO on the label.
Currently I have a program that goes,
Code:
IfEqual, AnyKey, %ApoKey101_11%
Apo_Continue := ApoFn_101_11()
Else IfEqual, AnyKey, %ApoKey102_11%
Apo_Continue := ApoFn_102_11()
Else IfEqual, AnyKey, %ApoKey103_11%
Apo_Continue := ApoFn_103_11()
Else IfEqual, AnyKey, %ApoKey104_11%
Apo_Continue := ApoFn_104_11()
...
for around 87 kilobytes. I think I'd do better with some array addressing and one of the InStr functions. I also intend that the contents of the ApoKeyN_N array are arbitrary, but I guess I could sort 'em. This is where I'd prefer database commands, but scripting isn't for purists.
