Also, if there is any scope ambiguity, it helps to be explicit:

send "stackInitialize" to stack "stackA" or send "stackInitialize" to me (if the card doesn't handle it, it'll go to the stack)

or even

set the defaultStack to "stackA"

Mark


On 3 Jan 2006, at 16:34, Rob Cozens wrote:

Morning Dave,

I have number of stacks:

StackA
StackB
StackC

In the preOpenStack hander of Card 1 of StackA, I load some other stacks using the:

go invisible stack "StackB"
close stack "StackB"

(The above it just to get the stack loaded and to setup some values that are needed by StackA)

Then I do the following:

send "StackInitialize" to this stack

Which should (unless I am wrong) call the "StackInitialize" handler in StackA.

I cannot tell you positively what is going wrong; but offer the following comments and suggestions:

* Unless the destroyStack property of Stack B is true, it is still in RAM after you close it. Apparently it is (at least sometimes) still in the message path despite being closed.

* You _might_ solve the problem by adding to the StackInitialize handlers:

if the name of the target is not the name of me then pass StackInitialize

* You can initialize variables and such from Stack B without opening it:

Instead of 'go invisible stack "Stack B"', try 'start using stack "Stack B"'. In Stack B's stack script add--

        on libraryStack
                -- initialization
        end libraryStack

* You can get & set values for Stack B without going to it:

        get field x of card y of stack "Stack B"
set the icon of button q of card r of stack "Stack B" to myIcon

Rob Cozens CCW
Serendipity Software Company

"And I, which was two fooles, do so grow three;
 Who are a little wise, the best fooles bee."

 from "The Triple Foole" by John Donne (1572-1631)
_______________________________________________
use-revolution mailing list
[email protected]
Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
http://lists.runrev.com/mailman/listinfo/use-revolution

_______________________________________________
use-revolution mailing list
[email protected]
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-revolution

Reply via email to