Hi, the problem is "Note: I had set the "USEMX" option in flash develop to true..." Setting the option to true, means mtasc is passed a flag -mx which means: do NOT use the mx classes.
So you are not compiling the delegate class into your project. If you want to use the -mx flag, simply create an injection swf, that contains: import mx.utils.Delegate; var cls0:Delegate; greetz JC On 4/11/07, dr.ache <[EMAIL PROTECTED]> wrote:
scope problem. try to create the Delegate before applying it to the onEnterFrame function like that: function new() { var del:Funtion = Delegate.create(this,traceIt); _root.onEnterFrame = del; } problem arises because you are in _root.onEnterFrame. your "this" will point to _root, not on your class instance. try it out! > > Note: I had set the "USEMX" option in flash develop to true... > > import mx.utils.Delegate; > class New { > > function New() { > _root.onEnterFrame = Delegate.create(this, traceIt); > } > private function traceIt() { > trace("tracing"); > } > } > > well this should trace "tracing" on frame rate, but it doesn't... even > if i > don't use delegate and i i do: _______________________________________________ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com
_______________________________________________ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com