# Using array to arrange subnav buttons

**URL:** https://forum.kirupa.com/t/using-array-to-arrange-subnav-buttons/113072
**Category:** Uncategorized
**Created:** [June 14, 2004, 7:09pm UTC](https://forum.kirupa.com/t/using-array-to-arrange-subnav-buttons/113072 "2004-06-14T19:09:22Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![JustinM](https://avatars.discourse-cdn.com/v4/letter/j/47e85d/32.png) [@JustinM](https://forum.kirupa.com/u/JustinM)
#### Post date: [June 14, 2004, 7:09pm UTC](https://forum.kirupa.com/t/using-array-to-arrange-subnav-buttons/113072/1 "2004-06-14T19:09:22Z")

</div>

I may be making this much harder than it should be. What I’m trying to do is create a navigation system which starts with for example a main navigation button named about us. On rollover, I want it to call a prototype that displays my subnavigation one button following the next. The code I have so far is as follows:

```auto

MovieClip.prototype.makemenu = function(thearray) {
	for (i=1; i<=thearray.length; i++) {
		textdisplay.text = textdisplay.text + thearray*;
		buttonName = this.thearray*;
		buttonName._y = buttonName._y + (30 * i);
		}
};
}

```

The array that I’m passing contains instance the names of the three subnavigation buttons that I want to reposition. So ideally, on rolling over the About Us button, I want to drop down the first subnav button, then the second, then the third. Each one would pop down after the previous has finished moving. Any suggestions would be appreciated!
