Ver Mensaje Individual
  #1 (permalink)  
Antiguo 05/08/2010, 13:06
Monti
 
Fecha de Ingreso: agosto-2010
Mensajes: 4
Antigüedad: 13 años, 8 meses
Puntos: 0
Problema con gotoAndPlay con variable externas

Hola,
Estoy intentando hacer que en función de una variable que recojo de la web, mi pelicula de flash se desplace a un fotograma o a otro, el código es el siguinte:

contenedor.text=_root.B;
var OPC:Number;
OPC=_root.B;
contenedor.text=OPC;
trace (OPC);
if (OPC==1){
this.gotoAndPlay (81);
}
if (OPC==5){
this.gotoAndPlay (86);
}
if (OPC==6){
this.gotoAndPlay (91);
}
if (OPC==21){
this.gotoAndPlay(35);
trace("Entro 21");
}
if (OPC==22){
this.gotoAndPlay (36);
}
if (OPC==23){
this.gotoAndPlay (41);
}
if (OPC==24){
this.gotoAndPlay (46);
}
if (OPC==31){
this.gotoAndPlay (51);
}
if (OPC==32){
this.gotoAndPlay (56);
}
if (OPC==33){
this.gotoAndPlay (60);
}
if (OPC==34){
this.gotoAndPlay (64);
}
if (OPC==41){
this.gotoAndPlay (68);
}
if (OPC==42){
this.gotoAndPlay (73);
}
if (OPC==43){
this.gotoAndPlay (76);
}
if (OPC==44){
this.gotoAndPlay (79);
}
if (OPC==""){
this.gotoAndPlay (1);
}

El problema es que no funciona bien en algunos navegadores. Los trace y lo de contenedor es para hacer debug y ver si esta recogiendo la variable y lo hace bien. Cada numero que recojo de fuera del swf es una opción de un menu. y siempre se queda en la misma opción.

Se puede ver en:

http://www.proadeon.com/vp2/uk/index.php

Alguien puede decirme como forzar que se desplace al fotograma que le pido???