Script after suspend do not want to unsuspend
Posted: 01 Aug 2021, 18:20
I have problem with my code: When I click F6 key my script suspend and when I click it again it does not unsuspend. Also after clicking t key and after F6 key MsgBox don't work.
My idea was this: If I run secound label, first label can't work, after secound label is done, first label can work.
My code:
My idea was this: If I run secound label, first label can't work, after secound label is done, first label can work.
My code:
Code: Select all
global abc:=true
Firstlabel:
if(abc=true){
Suspend
ToolTip % A_IsSuspended ? "Script is off" : "", 400, 0
}
else{
MsgBox,, Script, ERROR
}
Return
;```````````````````````````````````````````````````````````````````````````````````````````
Secoundlabel:
~t::
Suspend On
abc:=false
Loop
if (GetKeyState("Enter", "P") || GetKeyState("Escape", "P"))
break
Suspend Off
abc:=true
return