Actually I just realized that might not work, since it looks like the
variable is declared locally within the function, not at the top of
your class (although its hard to tell, is this on a timeline, or in a
class?). So you'd probably have to do:
this.getChildByName("holder").getChildByName("child
Misconception correction time!
Read my article:
http://www.actionscript.org/resources/articles/943/1/Actionscript-and-timelines/Page1.html
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flash
Woops, that should be:
childOne.getChildByName("grandchild")
On Tue, Sep 28, 2010 at 11:20 AM, Matt S. wrote:
> Did you try:
>
> childOneMC.getChildByName("grandchild")
>
> ?
>
> You're already defining the variable childOneMC at the top level, so
> there's no reason to reach down into holder to
Did you try:
childOneMC.getChildByName("grandchild")
?
You're already defining the variable childOneMC at the top level, so
there's no reason to reach down into holder to get it. Just my 2ยข,
hth...
.m
On Tue, Sep 28, 2010 at 10:48 AM, Lehr, Theodore
wrote:
> holder.getChildByName("childOneMC"
So I have a mc that has another mc inside of it... I have:
var holder:Sprite = new Sprite();
holder.name = "holderMC";
addChild(holder);
var childOne:childMC = new childMC();
childOne.name = "childOneMC";
holder.addChild(childOne);
now childOne has a mc inside of it (let's call it "grandchi
5 matches
Mail list logo