Differences between cantAbort and allowInterrupts ?.

Got a LiveCode personal license? Are you a beginner, hobbyist or educator that's new to LiveCode? This forum is the place to go for help getting started. Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller

Post Reply
richmond62
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 9356
Joined: Fri Feb 19, 2010 10:17 am
Location: Bulgaria

Re: Differences between cantAbort and allowInterrupts ?.

Post by richmond62 » Mon Apr 12, 2021 4:07 pm

complements
?
SShot 2021-04-12 at 18.06.20.png
-
Do you mean 'opposites'?

andresdt
Posts: 146
Joined: Fri Aug 16, 2019 7:51 pm

Re: Differences between cantAbort and allowInterrupts ?.

Post by andresdt » Mon Apr 12, 2021 4:27 pm

jackyjoy123 wrote:
Mon Apr 12, 2021 3:16 pm
Hello,

What are the differences between "cantAbort" and "allowInterrupts"? They appear in the Dictionary to be complements of each other, except that in their default settings of False would appear to conflict.

thanks
jackyjoy
Hello @jackyjoy123
The difference that I can see between these two properties.
It is that cantAbort is a property that will only affect one stack. Whereas allowInterrupts is a property that will affect all stacks. Since this last property is established to the motor and not to a stack. So we can say that if you set allowInterrupts to false, all stacks will behave as if their cantAbort is true. Now if allowInterrupts is true, stacks with cantAbort set to true will not allow their controllers to be interrupted. Well that's what I can understand, maybe I'm wrong and someone can help us understand this jjj

Setting the allowInterrupts property to false is functionally equivalent to setting the cantAbort property to true for each open stack.

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 7228
Joined: Sat Apr 08, 2006 8:31 pm
Location: Minneapolis MN
Contact:

Re: Differences between cantAbort and allowInterrupts ?.

Post by jacque » Tue Apr 13, 2021 4:57 pm

AllowInterrupts also has a related function "interrupt" that tells you when a user tries to abort a handler. I didn't know that until now.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

Post Reply

Return to “Getting Started with LiveCode - Complete Beginners”