# Nested movieclips?

**URL:** <https://forum.kirupa.com/t/nested-movieclips/229150>\
**Category:** Uncategorized\
**Created:** [June 14, 2007, 1:37pm UTC](https://forum.kirupa.com/t/nested-movieclips/229150 "2007-06-14T13:37:02Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![bardic](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/bardic/32/3708_2.png) [@bardic](https://forum.kirupa.com/u/bardic)\
**Post date:** [June 14, 2007, 1:37pm UTC](https://forum.kirupa.com/t/nested-movieclips/229150/1 "2007-06-14T13:37:02Z")

</div>

So I’m trying to simply nest some MCs and draw some squares within the nested clips.

```auto
nextDepth = this.getNextHighestDepth();

this.createEmptyMovieClip("mainMenu",nextDepth);
mainMenu.createEmptyMovieClip("menu1",nextDepth);
mainMenu.createEmptyMovieClip("menu2",nextDepth);
mainMenu.menu2._x = 250;

mainMenu.menu1.moveTo(0,0);
mainMenu.menu1.beginFill(0x000088);
mainMenu.menu1.lineTo(100,0);
mainMenu.menu1.lineTo(100,100);
mainMenu.menu1.lineTo(0,100);
mainMenu.menu1.endFill();

mainMenu.menu2.moveTo(150,0);
mainMenu.menu2.beginFill(0x000088);
mainMenu.menu2.lineTo(250,0);
mainMenu.menu2.lineTo(250,100);
mainMenu.menu2.lineTo(150,100);
mainMenu.menu2.endFill();

```

This is just my first step in a build and I wanted to test that the movieclips were nesting properly. The problem isn’t the squares but that the first movieclip isn’t displaying. And when I comment out the second MC (menu2) it displays fine.  
If anyone would point how what I’m doing wrong or send me in the right direction with a tutorial, that would be wonderful.
