Code: Select all
global vars := []
, vars_i := 0
add("foo")
add(var) {
vars.Push(var)
vars_i++
alias := vars[vars_i]
Gui,mc:Add,Text,V%alias%
}
so I google "ahk dynamic global variable" on google.Error: A control's variable must be global or static.
It turns out I can use "global local" to solve this issue,
but it stil feedback another error
I've tried
Code: Select all
global %alias%
Code: Select all
global
local %alias%
This took me a really long time