cantDelete

J. Landman Gay jacque at hyperactivesw.com
Thu Dec 15 23:34:45 EST 2011


On 12/15/11 8:11 PM, Mark Wieder wrote:
> All-
>
> Am I missing something here? This might be one of those in-the-running
> stupid moments. Does setting the cantDelete property of a stack
> actually do anything?
>
> I thought it prevented a mainstack from being removed from memory with
> a delete command, but it doesn't do that. I've read the documentation
> a couple of times now and I can't see what I'm missing.

It doesn't look like the docs even address that. It talks about what 
deletion does, but not what cantdelete does when referencing a 
mainstack. Maybe it's only good for substacks, and prevents them from 
being removed from the stack file?

>
> Second question: since cantDelete doesn't do what I want, is there a
> different way to prevent the delete function from removing a mainstack
> from memory? What I'm trying to do is keep a stack in memory even if
> the following is executed
>
> put the openstacks into tStacks
> repeat for each line tStack in tStacks
>    delete stack tStack
> end repeat
>

Aside from polling and re-opening the stack, I can't think of a way. But 
the cantdelete behavior sounds close enough to a bug that you might want 
to report it. If it isn't a bug, maybe it could be a feature request. 
Your expectations seem reasonable.

-- 
Jacqueline Landman Gay         |     jacque at hyperactivesw.com
HyperActive Software           |     http://www.hyperactivesw.com




More information about the use-livecode mailing list