Communication between modal stack and main stack

Robert Brenstein rjb at robelko.com
Fri Nov 4 06:15:12 EST 2005


>Hi
>
>I use several modal stacks  to communicate with the user.
>My first question is:
>
>Is there a way to pass informasjon from a modal stack back to the 
>function on the stack that
>opened it? Like "Return"? I use a custom property for now....

check out the dialogData (global) property.

>When the modal stack closes the function in the main stack that 
>opened it continues. Just what I want. But for the remaining message 
>path in the function
>I have to refer to the main stack - even if the fuction resides in 
>the main stack. Or else I get a background not found error.
>
>How can I prevent this. Do I need to set the focus back on the main stack?

Rev should automatically reset focus and, more importantly, the 
defaultStack property to your main stack when a substack closes. A 
situation where I had seen this malfunction was when there was an 
invisible stack which for some reason got the attention. Check what 
the defaultStack upon return from dialog is and may be this will give 
you a clue.

Robert



More information about the use-livecode mailing list