As soon as you removeChild on child1, it loses the reference to the parent. If you want to continue on that tightly-coupled path, I would store a temporary reference to the parent, then unload child one and use the temporary reference to parent to load the new child.
The design I would choose is to create an event that is broadcast from child1. In the parent, I would add an event listener to child1. When the event fires, unload 1 and load 2 from the eventlistener in parent. -jonathan On Tue, May 11, 2010 at 12:33 PM, Mattheis, Erik (MIN - WSW) < [email protected]> wrote: > Did you mean to say removeChildAt(0)? > > Have you tried Loader.unload()? > > _ _ _ > Erik Mattheis > Senior Web Developer > Minneapolis > T 952 346 6610 > C 612 377 2272 > > Weber Shandwick > Advocacy starts here. > > PRWeek Global Agency Report Card 2009 - Gold Medal Winner > The Holmes Report Global Agency of the Year > PR News Agency of the Year > > > -----Original Message----- > From: [email protected] [mailto: > [email protected]] On Behalf Of Lehr, Theodore > Sent: Tuesday, May 11, 2010 10:15 AM > To: Flash Coders List > Subject: [Flashcoders] changing parent from child > > I have a container swf - with a child... I want to have a button in the > child that will change the child in the parent... so if I have: > > Parent.swf>Child 1.swf > > Once I click on a button in child 1, I will have > > Parent.swf>Child 2.swf > > I have tried removeChild(0) to take out the original swf, but that only > seems to work once.... > _______________________________________________ > Flashcoders mailing list > [email protected] > http://chattyfig.figleaf.com/mailman/listinfo/flashcoders > > _______________________________________________ > Flashcoders mailing list > [email protected] > http://chattyfig.figleaf.com/mailman/listinfo/flashcoders > -- -jonathan howe _______________________________________________ Flashcoders mailing list [email protected] http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

