# Nesting MovieClip Objects?

**URL:** <https://forum.kirupa.com/t/nesting-movieclip-objects/226740>\
**Category:** flash\
**Created:** [May 23, 2007, 3:41pm UTC](https://forum.kirupa.com/t/nesting-movieclip-objects/226740 "2007-05-23T15:41:21Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![douglaae](https://avatars.discourse-cdn.com/v4/letter/d/c89c15/32.png) [@douglaae](https://forum.kirupa.com/u/douglaae)\
**Post date:** [May 23, 2007, 3:41pm UTC](https://forum.kirupa.com/t/nesting-movieclip-objects/226740/1 "2007-05-23T15:41:21Z")

</div>

Hello all,

I’m trying to convert an AS2 app to AS3, and I’ve run into a problem when I try to nest MovieClip objects. I’m trying to do this:

var parentClip:MovieClip = new MovieClip();  
var childClip:MovieClip = new MovieClip();  
parentClip.addChild(childClip);  
addChild(parentClip);

When I do traces on each MovieClip object separately, it looks good. However, When I do: trace(parentClip.childClip), it shows “undefined,” and any objects underneath childClip are inaccessible through parentClip.childClip as well due an error related to the “undefined.” How does one nest MovieClips in AS3?

Thanks!

Andy
