# Fading-In dynamically loaded buttons

**URL:** <https://forum.kirupa.com/t/fading-in-dynamically-loaded-buttons/209445>\
**Category:** flash\
**Created:** [December 8, 2006, 9:01pm UTC](https://forum.kirupa.com/t/fading-in-dynamically-loaded-buttons/209445 "2006-12-08T21:01:17Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![dessoya](https://avatars.discourse-cdn.com/v4/letter/d/ed655f/32.png) [@dessoya](https://forum.kirupa.com/u/dessoya)\
**Post date:** [December 8, 2006, 9:01pm UTC](https://forum.kirupa.com/t/fading-in-dynamically-loaded-buttons/209445/1 "2006-12-08T21:01:17Z")

</div>

So, I was fooling around with XML and AS.  
I finally managed it to load the buttons via the .xml file.

The only problem is, they all load at the same time.  
Is it possible to set an interval to each button, so it fades one after another?  
Like, I dunno. a 0.1 second per button?

Here is the code so far…

```auto

menu = new XML(); menu.ignoreWhite = true; menu.load("menu.xml");
menu.onLoad = function(){
	items = this.firstChild.childNodes;
	for(counter=0; counter<=items.length-1; counter++){
		_root.attachMovie( "menu_item", "item"+counter, counter);
		_root["item"+counter].boxname.text = items[counter].attributes.bname;
		_root["item"+counter]._x = counter*18;
                _root["item"+counter]._y = 225;
	}
}

```
