I need to use some variables inside OnMessage handlers.
Here is example:
Why does myVar is empty?
Code: Select all
myVar = "hello world"
Gui, New, hwndhGui AlwaysOnTop Resize
GuiControl, Font, hwndhGui
Gui, Show, H120 x700 y200
OnMessage(0x201, "WM_LBUTTONDOWN")
return
;MouseClick handler
WM_LBUTTONDOWN()
{
OutputDebug myVar: %myVar%
}