# Modifying \_y value does not work

**URL:** <https://forum.kirupa.com/t/modifying--y-value-does-not-work/279282>\
**Category:** flash\
**Created:** [January 12, 2009, 8:58pm UTC](https://forum.kirupa.com/t/modifying--y-value-does-not-work/279282 "2009-01-12T20:58:05Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![BuG56](https://avatars.discourse-cdn.com/v4/letter/b/c57346/32.png) [@BuG56](https://forum.kirupa.com/u/BuG56)\
**Post date:** [January 12, 2009, 8:58pm UTC](https://forum.kirupa.com/t/modifying--y-value-does-not-work/279282/1 "2009-01-12T20:58:05Z")

</div>

Hello Everyone,

I’m having the most frustrating problem. I’ve got a simple code that just refuses to work for some reason.

**(AS2)**

```auto
            
for (a = this.ref + 1; a < _root.Boxes.length; a++)
    {
    //Set property does not work                
    setProperty(_root.Boxes[a],_y,this._y+(a*25));

    //And neither does modifying it directly
    _root.Boxes[a]._y = this._y+(a*25);

     //This works, but it's not what I need
    //_root.Boxes[a]._y = this._y;
    }

```

\_root.Boxes is an array which points to objects.  
\_root.Boxes.length = 52

this. ref is 0

Using trace, I’ve found that a\*25 is correct, the objects I’m trying to access are correct, and that the for loop runs, but I can visually see that the elements have not moved a muscle :shifty:. What’s going on here?

Thank you for your help,  
-BuG56
