# Rerring to my clip by name?

**URL:** <https://forum.kirupa.com/t/rerring-to-my-clip-by-name/284118>\
**Category:** flash\
**Created:** [March 15, 2009, 4:29pm UTC](https://forum.kirupa.com/t/rerring-to-my-clip-by-name/284118 "2009-03-15T16:29:28Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Alber\_Kidd](https://avatars.discourse-cdn.com/v4/letter/a/e47c2d/32.png) [@Alber\_Kidd](https://forum.kirupa.com/u/Alber_Kidd)\
**Post date:** [March 15, 2009, 4:29pm UTC](https://forum.kirupa.com/t/rerring-to-my-clip-by-name/284118/1 "2009-03-15T16:29:28Z")

</div>

Hi,

I have created a loop to add my clips by class and give them a name

```
      tempClip = new clientsThumbs*(); 
    tempClip.x = xPos;
    tempClip.y = yPos;
    tempClip.name = clientsNames*;
    tempClip.addEventListener(MouseEvent.CLICK, focus);
    addChild(tempClip);
    xPos = xPos +200;

```

Then I want to loop through these clips and change the alpha, I have tried casting as I thought that was how you do it but I get the ‘cannot convert string’ error

```
        for(var i:int = 0; i&lt;clientsName.length; i++) {
            
       clientsNames*.alpha= 0.5;

       //OR MovieClip(clientsNames*).alpha= 0.5;
            
        }

```

How do I reference my instances by name  
 ![](http://www.kirupa.com/forum/styles/kirupaProblue/statusicon/user_online.gif)[![](http://www.kirupa.com/forum/styles/kirupaProblue/buttons/report.gif) ![](http://www.kirupa.com/forum/styles/kirupaProblue/misc/progress.gif) [URL=“http://www.kirupa.com/forum/editpost.php?do=editpost&p=2447952”] ![](http://www.kirupa.com/forum/styles/kirupaProblue/buttons/edit.gif)](http://www.kirupa.com/forum/report.php?p=2447952)
