Scripts that are already running

DunbarX at aol.com DunbarX at aol.com
Fri Sep 24 13:15:54 EDT 2010


Jacques, et al.

The "wait with messages", which I know about, is compact and cool. But that 
code needs to reside within the running handler. As do, in their own way, 
all the other comments from everyone. For example, BonnMike notes you can 
read the state of a property while a handler is running. Certainly you can, but 
only from within the handler.

I was asking if any state of the machine can be accessed from outside a 
running handler. I read from all the responses, as I thought, that it cannot.

Say a variable is gettinig incremented in a repeat loop. Its state changes 
as the loop progresses. Can this state be returned to the engine from some 
externally running process, one that would be able to monitor handler 
variables on the fly. It would require, essentially, that the handler be 
interrupted continuously. I don't think this is part of the xTalk world. I am not sure 
about other procedural languages.

This all came about because someone wanted a single universal watchdog on 
his stack. He had several handlers in several places, all of which could 
create a condition he wanted to act upon. So the "send in time" handler fit that 
bill. If he created yet another such handler somewhere, it would be 
covered. But it occurred to be that if the condition was met and the handler still 
had much to do and might take a long time to do it, then the condition could 
not be dealt with until that handler ends. It seemed intriguing to think 
that something could monitor, say, the state of variables, from outside the 
handler while it was running.

Anyone think this is a useful, perhaps monumental, feature?

Craig



More information about the Use-livecode mailing list