# Attaching movieclips

**URL:** <https://forum.kirupa.com/t/attaching-movieclips/88464>\
**Category:** programming\
**Created:** [April 29, 2005, 1:38pm UTC](https://forum.kirupa.com/t/attaching-movieclips/88464 "2005-04-29T13:38:06Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Cybernoid](https://avatars.discourse-cdn.com/v4/letter/c/ba9def/32.png) [@Cybernoid](https://forum.kirupa.com/u/Cybernoid)\
**Post date:** [April 29, 2005, 1:38pm UTC](https://forum.kirupa.com/t/attaching-movieclips/88464/1 "2005-04-29T13:38:06Z")

</div>

Why doesn’t this work? This code is in one of the movieclips on the stage inside onEnterFrame-handler.

```auto

    if(_root.printed==0)
    {
      
        for(i=0;i<_root.lives;i++)
        {    
        _root.attachMovie("lifex", "lives"+i, 30000+i);
        axa=24*i;
        yxy=200;
        setProperty ("lives"+i, _x,axa);
        setProperty ("lives"+i, _y,200);
        }        
    
    _root.printed=1;
    }

```

When I list the objects it says all the objects are there, but I only see one. What’s wrong?
