Ver Mensaje Individual
  #4 (permalink)  
Antiguo 25/01/2011, 12:26
Avatar de golem44
golem44
 
Fecha de Ingreso: enero-2009
Ubicación: barcelona
Mensajes: 483
Antigüedad: 15 años, 4 meses
Puntos: 22
Respuesta: Pasar variables en boton

supongamos que tenemos 2 botones instanciados como bot1 y bot2 :
Cita:
for (var i:Number = 1; i<=2; i++) {
this["bot"+i].me = i;
////PRESS:
this["bot"+i].onPress = function() {

_global.seccion = this.me;
trace("bot: "+seccion);

}
}
espero ayudar, saludos.