Preopenstack confusion

Rob Cozens rcozens at
Wed Feb 6 14:38:00 CST 2002

Moi:>Since your desire is to monitor stack status
>throughout the session, a global will work best because it is "reset"
>automatically when the runtime engine quits.

Michael, et al:

You could use one global variable and one handler for all stacks that need

	on preOpenStack
		global openedStacks
		put openedStacks into stackList	-- I move globals to local
variables before list
					-- operations...posibly not needed
		put true into listMe
		get the id of the target
		repeat for each line l in stackList
			if it is not l then next repeat
			put false into listMe
			exit repeat
		end repeat
		if listMe then
			put it&return after openedStacks
			cleanMeUp -- generic call for clean up routines here
		otherPreopenLogic -- generic call for "every open" routines
	end preOpenStack

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)

More information about the use-livecode mailing list