Jump to content

Coding an Abort button


Guest perryman07
 Share

Recommended Posts

Guest perryman07

I have a simple GUI with only two buttons, a GO and an Exit. But sometimes my program will mess up and click somewhere where it shouldn't or something isn't copied and pasted in the right place for some reason, and the chain of events that follow are just ugly and sometimes harmful to files and program settings. Right now all I can do is just Ctrl+Alt+Delete and terminate the program when it starts acting up. I'm wondering if there is a way to create a shortcut key or just another button on my GUI that would abort or exit out of the Case that is currently running, so I can minimize the damage done when my program goes crazy. Is there a way to code in something that constantly checks to see if a button has been hit and if it does then it will exit the Case loop and return main Select loop?

Link to comment
Share on other sites

  • Moderators

I'm wondering if there is a way to create a shortcut key or just another button on my GUI that would abort or exit out of the Case that is currently running, so I can minimize the damage done when my program goes crazy.

Have you looked at "ProcessClose" in the help file?

Is there a way to code in something that constantly checks to see if a button has been hit and if it does then it will exit the Case loop and return main Select loop?

Check out _IsPressed in the "Search" function of the forum. This may help you.

Hope this helps.

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.

Link to comment
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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...