# Cleanest way to dynamically target library child MC?

**URL:** <https://forum.kirupa.com/t/cleanest-way-to-dynamically-target-library-child-mc/288884>\
**Category:** Uncategorized\
**Created:** [May 22, 2009, 11:58am UTC](https://forum.kirupa.com/t/cleanest-way-to-dynamically-target-library-child-mc/288884 "2009-05-22T11:58:08Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![humbucker](https://avatars.discourse-cdn.com/v4/letter/h/278dde/32.png) [@humbucker](https://forum.kirupa.com/u/humbucker)\
**Post date:** [May 22, 2009, 11:58am UTC](https://forum.kirupa.com/t/cleanest-way-to-dynamically-target-library-child-mc/288884/1 "2009-05-22T11:58:08Z")

</div>

Hello,

I got a simple question that confuses me alittle, cause I want to code the best way.

So, I’m using a document class file to manage my animation and I took the habit to work with linked class names for my library MC.

In my code I got something like :

```auto

public var BoxMC:_Box = new _Box();

```

and then I use the common addChild and other functions to work with it.

Anyway, my website template is composed by a lot of separate MC and I thought it would be easier to wrap them all in a single MC (easier for global centering on screen and so on)  
I still can access the children of this new born MC with codes like :

```auto

BoxMC.menuLink1.alpha=1;

```

But is it a good usage of AS3 ?  
What should I do if it’s bad to create simply a global container that hold my separates MC and still can target all the children easily ?

Thank you !
