# Movie clip name

**URL:** <https://forum.kirupa.com/t/movie-clip-name/325204>\
**Category:** Uncategorized\
**Created:** [October 1, 2011, 8:56am UTC](https://forum.kirupa.com/t/movie-clip-name/325204 "2011-10-01T08:56:36Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Delpierooo](https://avatars.discourse-cdn.com/v4/letter/d/c57346/32.png) [@Delpierooo](https://forum.kirupa.com/u/Delpierooo)\
**Post date:** [October 1, 2011, 8:56am UTC](https://forum.kirupa.com/t/movie-clip-name/325204/1 "2011-10-01T08:56:36Z")

</div>

Hello,

I have one question. I am dinamicly creating movie clip(see code below). I give each movie clip a name that has a diffrent nubmer at the end(myMovieClip1,myMovieClip2,…). In the createEmptyMovieClip this works fine, but when I want to do something with the new created mc (\_root.designer.nameMC.lineStyle(0.5, 0xFF0394, 100); ) I can’t use the string variable to acccess it. How can I access this movieclip with the name given in the createEmptyMovieClip method?

I shuold probably (somehow) set movie clips instance name, right?

Code:

```
           //loop
            var nameMC:String= "myMovieClip"; 
           nameMC=nameMC+loopNumber.toString();
           _root.designer.createEmptyMovieClip(nameMC, firstDepth+loopNumber); 
           _root.designer.nameMC.lineStyle(0.5, 0xFF0394, 100); //????? nameMC not working

```

Thanks for your help.
