# Access to MovieClip from root

**URL:** <https://forum.kirupa.com/t/access-to-movieclip-from-root/301443>\
**Category:** Uncategorized\
**Created:** [December 9, 2009, 11:27am UTC](https://forum.kirupa.com/t/access-to-movieclip-from-root/301443 "2009-12-09T11:27:16Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![awariat](https://avatars.discourse-cdn.com/v4/letter/a/919ad9/32.png) [@awariat](https://forum.kirupa.com/u/awariat)\
**Post date:** [December 9, 2009, 11:27am UTC](https://forum.kirupa.com/t/access-to-movieclip-from-root/301443/1 "2009-12-09T11:27:16Z")

</div>

```php
var Root:MovieClip
var container=MovieClip;

function menuPress() {
    trace("trace");
}

function doIT(parameters,WIDTH,HEIGHT) {

        container=MovieClip(parent.parent.parent);
        trace(container.name)//HELP
        Root=MovieClip(parent.parent.parent.parent);
        trace(Root)//[object MainTimeline]
        trace(Root.name)//root1
        //container.getChildByName("help").getChildByName("help").content.menuPress();//1*) it works
        
        Root.getChildByName("HELP").getChildByName("help").getChildByName("help").content.menuPress();
        //2*) 
        // it doesn't work
        //1061: Call to a possibly undefined method getChildByName through a reference with static type flash.display:DisplayObject.

}
}

```

why 1\* works but 2\* only one level higher (root) doesn’t work

the error start immidiately when I test current swf not main movie which load this swf

sorry for my english 🙂
