# Using array objecs as target names HELP NEEDED

**URL:** <https://forum.kirupa.com/t/using-array-objecs-as-target-names-help-needed/234791>\
**Category:** Uncategorized\
**Created:** [August 6, 2007, 8:03am UTC](https://forum.kirupa.com/t/using-array-objecs-as-target-names-help-needed/234791 "2007-08-06T08:03:29Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![chevron8653](https://avatars.discourse-cdn.com/v4/letter/c/6f9a4e/32.png) [@chevron8653](https://forum.kirupa.com/u/chevron8653)\
**Post date:** [August 6, 2007, 8:03am UTC](https://forum.kirupa.com/t/using-array-objecs-as-target-names-help-needed/234791/1 "2007-08-06T08:03:29Z")

</div>

hi there.

well i have several movie clips and on a keypress the instancename of one of em will get pushed into an array i have set up and that movie clip is animated of a few hundred frames and what i want to do is make it i can target the movie clips but using the array positions to target them like instead of writing

```auto
_root.one_mc.gotoAndPlay(36)

```

i want to be able to type

```auto
_root.namearray[1].gotoAndPlay(36)

```

so what ever clips instance name is pushed into namearray position one will be the one tht goes to and plays their frame 36 so on for upto the 7 positions i have em pushed up to on that array.

the code ive shown u dosent work ive tried adding + inbetween each word but it still fails and id like to do it that way because i have 36 symbols and coding each one to go to the frames i want on their own would take ages this way it would be shorter, much shorter.

hope its not to confusing for u on what i want to do and thanks in advanced for ne help u can give.

ill check back later to see ne replies.

thanks
