# Trace works, but array not populating

**URL:** <https://forum.kirupa.com/t/trace-works-but-array-not-populating/283219>\
**Category:** flash\
**Created:** [March 3, 2009, 7:58pm UTC](https://forum.kirupa.com/t/trace-works-but-array-not-populating/283219 "2009-03-03T19:58:41Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Skarab](https://avatars.discourse-cdn.com/v4/letter/s/ba8739/32.png) [@Skarab](https://forum.kirupa.com/u/Skarab)\
**Post date:** [March 3, 2009, 7:58pm UTC](https://forum.kirupa.com/t/trace-works-but-array-not-populating/283219/1 "2009-03-03T19:58:41Z")

</div>

K, I’m stumpered. I’ve got some xml that I want to use to populate the labels on an array of buttons that I’m putting in with attachMovie. the button(s) load (well, the first one does) and I’ve got a trace statement that shows the exact data I want in the button labels. But the numbers just refuse to appear in the button labels.

the labeling is correct; I’ve been looking at this for three days and checked the path and naming at least a dozen times.

```auto
for(i=0; i<total; i++){
        patMenuHolder_mc.attachMovie("patentBtn", "patentBtn"+i, i, {_x:xPos, _y:yPos})
            //establishes the distance of the array buttons from each other.
            this.yPos += ["patentBtn"+i]._height+3;
            //add the patent numbers to the button labels
            this["patentBtn"+i].buttonLabel_mc.labelText_txt.text = xmlNode.childNodes*.attributes.number;
            
            trace(xmlNode.childNodes*.attributes.number);

```

Could “this” be conflicting with the “patMenuHolder\_mc”? I’ve removed and replaced them both a few times in different combinations with no effect.

the entire file is pretty large, but will be happy to upload if someone wants a closer look.
