Jump to content
Sign in to follow this  
Jussip

Pause script hotkey

Recommended Posts

Jussip

Hey,

Is there any way to put hotkey to script, so i press Insert button, and the script pauses? And if i press againg, it continues?

If there is, please post it here.

-Jiibah

Share this post


Link to post
Share on other sites
Andreik

Hey,

Is there any way to put hotkey to script, so i press Insert button, and the script pauses? And if i press againg, it continues?

If there is, please post it here.

-Jiibah

You can do something like this:

HotKeySet("{PAUSE}","ScriptPause")
Global $STATE = 0

While 1
    TrayTip("Script","Run",1)
    Sleep(15)
WEnd

Func ScriptPause()
    $STATE += 1
    Do
        TrayTip("Script","Pause",1)
        Sleep(15)
        $VAL = Mod($STATE,2)
        
    Until $VAL = 1
EndFunc

When the words fail... music speaks

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×