Aborting a script

Ken Ray kray at sonsothunder.com
Thu Nov 25 11:09:55 EST 2004


On 11/25/04 6:53 AM, "Kaveh Bazargan" <kaveh at focalimage.com> wrote:

> I am developing on OS X. When I am in a loop with an "answer" dialog box, I
> can't find a way to abort the whole handler. I have tried command-. which I
> think worked in HyperCard.

Well, having an answer dialog inside of a loop makes cancelling tricky.
Command-. *does* work, it just has to be executed while script lines are
actually running, which isn't the case when you have an answer dialog being
displayed. However after you dismiss the dialog, it will go back to running
the rest of the script, at which point *if you're fast enough*, you can
command-. and get the Execution Error dialog.

However if you have something like this:

  on mouseUp
    repeat
      answer "Hey there!"
    end repeat
  end mouseUp

you might as well force-quit. ;-)

Ken Ray
Sons of Thunder Software
Web site: http://www.sonsothunder.com/
Email: kray at sonsothunder.com




More information about the use-livecode mailing list