Jump to content
Sign in to follow this  

Hot Key Pause Question

Recommended Posts

If your program is in the middle of a Function and you use the hotkey pause.

Will this pickup were is left off in the function or start it over?

I can tell which one mine is doing :think:


Run one of those examples, and you'll see with the tool tip when you pause it pauses at the number and restarts when you press pause again from that number.

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Share this post

Link to post
Share on other sites

It would appear to pick up where it left off.

; Press Esc to terminate script, Pause/Break to "pause"

Global $Paused
HotKeySet("{PAUSE}", "TogglePause")
HotKeySet("{ESC}", "Terminate")

While 1

Func TogglePause()
    $Paused = NOT $Paused
    While $Paused
        SplashTextOn("Paused","Script is Paused", 200, 100)

Func Terminate()
    Exit 0

Func doStuff()
    For $i = 1 to 100
        Tooltip("Count = " & $i, 0, 0)

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  

  • Create New...