I find this code on this thread: Suspending, Pausing, Hiding, Pulling Up GUI Window:
Gui % (MainGui:=!MainGui) ? "Hide" : "Show"
What does it do? I guess it's a kind of a simple if expression for hotkeys, but checking the examples on the two pages I don't see where it locates.
If SetTimer is used, the counter will only increase if that code is put inside the subroutine. If put outside, the counter stops.
Gui +LastFound +AlwaysOnTop +ToolWindow -Caption
Gui, Add, Text, vcounter, 00000
Gui, Show, NoActivate
SetTimer, Update, 100 ; 100 ms
Update:
counter++
GuiControl,, counter, %counter%
^esc::Gui % (MainGui:=!MainGui) ? "Hide" : "Show"
Return
Aucun commentaire:
Enregistrer un commentaire