Hi,

I often need millisecond precision and I'm very interested by this. I don't understand very well how to use the #target attribute of the timeout object. I work out fine timeout() when the #timeoutHandler is in a movie script - works great. But what does" "The targetObject identifies the name of the child object that contains the #timeoutHandler" exactly means? The child of which parent? I have tried with the #timeoutHandler in a member script, but it doesn't seem to work. I would be grateful if someone could provide a small example.

Thanks in advance,

Denis

==============================================
From Director Help:

When new() is used to create a timeout object, the timeoutPeriod sets the number of milliseconds between timeout events sent by the timeout object. The #timeoutHandler is a symbol that identifies the handler that will be called when each timeout event occurs. **The targetObject identifies the name of the child object that contains the #timeoutHandler.** If no targetObject is given, the #timeoutHandler is assumed to be in a movie script.

When a timeout object is created, it enables its targetObject to receive the system events prepareMovie, startMovie, stopMovie, prepareFrame, and exitFrame. To take advantage of this, the targetObject must contain handlers for these events. The?events do not need to be passed in order for the rest of the movie to have access to them.
==============================================



Denis Bel-Isle Ph.D. [EMAIL PROTECTED]

Institut des matériaux et systèmes intelligents
Pavillon Marie-Victorin, local D6-1004
Université de Sherbrooke
2500, boul. de l’Université
Sherbrooke (Québec)  J1K 2R1

Téléphone: (819) 829-7131
FAX : (819) 829-7141




On Thursday, July 24, 2003, at 12:01 PM, [EMAIL PROTECTED] wrote:


Message: 7
From: Thomas Higgins <[EMAIL PROTECTED]>
To: "'[EMAIL PROTECTED]'" <[EMAIL PROTECTED]>
Subject: RE: <lingo-l> loop every hour
Date: Wed, 23 Jul 2003 11:08:01 -0700
Reply-To: [EMAIL PROTECTED]

Rodrigo,

How can I implement an script to run every hour.

[snip]

And to be crystal clear, in order to "destroy" the timeOut object you must remember to use the forget() command and then set the timeOut reference to VOID:


gTimeOutObj.forget()
gTimeOutObj = VOID

The forget() commannd removes the timeOut object from the timeOutList, thus preventing it from firing off anymore. Setting the reference to VOID then clears the timeOut object from memory. Doing both of the above ensures proper clean-up of the object.



[To remove yourself from this list, or to change to digest mode, go to http://www.penworks.com/lingo-l.cgi To post messages to the list, email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED]). Lingo-L is for learning and helping with programming Lingo. Thanks!]

Reply via email to