Yeah if you hav a look at the code, I did exactly that in one spot..... I had a trace(_parent); in there..... but hte issue seems to be more so tha tthe button onPress is not being registered.
:::::::::::::::::::::: Dustin :::::::::::::::::::::: ---------- Original Message ----------- From: Mick Gow <[EMAIL PROTECTED]> To: Flashcoders mailing list <flashcoders@chattyfig.figleaf.com> Sent: Wed, 26 Oct 2005 09:28:34 +1000 Subject: Re: [Flashcoders] targets driving me insane > Not exactly giving a solution here but a tip :) > A really cool way to figure out targets is to trace them... > Even do a trace on (this) then trace (_parent) anywhere in any MC and trace > the paths in your code to see where you are - very handy way when you're in > path hell. > > On 10/26/05, lists <[EMAIL PROTECTED]> wrote: > > > > Hi there - I am about to go crazy here.... I am trying to target a button > > in a dynamic > > MC (attached from the Library). Each movie clip in the library already has > > the required > > buttons with an instance name. > > > > I have a MC on my main timeline called "menu_mc". > > Now in the timeline of "menu_mc" I have the following code: > > > > //l2 > > this.l1_mc.product_btn.onPress = function():Void { > > _parent.menu_mc.attachMovie("level2McProduct", "l2Product_mc", 12); > > _parent.menu_mc.l2Product_mc._x = 73.7; > > new Tween(_parent.menu_mc.l2Product_mc, "_alpha", Strong.easeOut, 0, 100, > > 3, true); > > new Tween(_parent.menu_mc.l2Product_mc, "_y", Strong.easeOut, 106, 0, 1, > > true); > > }; > > //l3 > > this.l2Product_mc.mens_btn.onPress = function():Void { > > trace(_parent); > > _parent.menu_mc.attachMovie("level3McMens", "l3Mens_mc", 13); > > _parent.menu_mc.l3Mens_mc._x = 189.5; > > new Tween(_parent.menu_mc.l3Mens_mc, "_alpha", Strong.easeOut, 0, 100, 3, > > true); > > new Tween(_parent.menu_mc.l3Mens_mc, "_y", Strong.easeOut, 106, 0, 1, > > true); > > }; > > > > the "l1_mc" was created with attachMovie earlier in the code, but is > > trimmed from here > > to save room (it functions as it should). The following: > > > > this.l1_mc.product_btn.onPress = function():Void > > > > also works as it should. Now the results of that are another MC attached > > to the timeline > > of the "menu_mc" instance. This all works, and my tweens, etc all work as > > expected. Now > > for some reason when I drill down one level deeper: > > > > this.l2Product_mc.mens_btn.onPress = function():Void > > > > the code stops working. I stuck a "trace" in there to see if the button > > event was even > > responding. Which it is not! I double, triple checked the button instance > > name and the > > so on... but it just never works. As you can see I had modified my path to > > use the > > previously attached MC. I even tried putting in the moviclip by hand and > > browsed to find > > the path (to make sure I had no mistakes)- and it appears I do not. > > > > I am at wits end here and going insane. Does anyone have any suggestions? > > Am I missing > > something? Is there a limitation in flash that I do not know about? > > > > :::::::::::::::::::::: > > Dustin > > :::::::::::::::::::::: > > > > _______________________________________________ > > Flashcoders mailing list > > Flashcoders@chattyfig.figleaf.com > > http://chattyfig.figleaf.com/mailman/listinfo/flashcoders > > > _______________________________________________ > Flashcoders mailing list > Flashcoders@chattyfig.figleaf.com > http://chattyfig.figleaf.com/mailman/listinfo/flashcoders ------- End of Original Message ------- _______________________________________________ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders