Q: Help on multiple buttons_loop_arrays

Hello friends, i`m a simple user of as2. Now when beginning a new year, I would want to begin to know a little more as3(because as3 is very powerfull)
but i have a mega problem :frowning:

i
my

in AS2 I wrote of the following way:

ap…of course…i work in timeline, and buttons on stage



myURLs = new Array("www.google.com","www.altavista.com",....) 
for (var i = 1; i<7; i++) { 
   var btn = this["but"+i]; 
   btn.id = i; 
   btn.url=myURLs* 

   btn.onRelease = function() { 
      trace(this.id)
      getURL(this.url) 
   } 

 btn.onRollOver = function() { 
      this.gotoAndPlay(2)
   } 


} 



deactivateItem=function(boton){ 
  for (var i = 1; i<7; i++) { 
    var btn = this["but"+i]; 
    if (btn==boton){ 
           btn.enabled=false
           btn._alpha=50
    }else{ 

           btn.enabled=true 
           btn._alpha=100 
    } 
  } 
} 



   btn.onRelease = function() { 
             deactivateItem(this) 
   }

i know the basic way to call button in as3
//***over mc1
function OverFunction(event:MouseEvent):void {
MC1.gotoAndPlay(2)
}
MC1.addEventListener(MouseEvent.MOUSE_OVER, OverFunction);

but i don`t know some way for work with arrays and loops

thanks in advance for any assistance
sorry for mi english…and…
happy new year for all
:slight_smile: