spii
06-15-2007, 12:19 AM
hey,
--> i have this code in flash:
import flash.external.ExternalInterface;
var result:Object = ExternalInterface.call("getTextFromFlash");
//writes in the inputtext what it receives from JavaScript
resultado.text = result.toString();
switch (result.toString()) {
case ("1") :
gotoAndStop("2");
case ("2") :
gotoAndStop("3");
}
stop();
--> and i have this in javascript:
function getTextFromFlash() {
return "1";
}
--> my problem is that when they communicate in the Inputtext apears - 1 - but the switch doesnt make a match. Also in IE 7 the text that apears is - undefined - so they don't communicate.
Can someone help me with this problem?? i already googled everything i could and found nothing that helped me.
--> i have this code in flash:
import flash.external.ExternalInterface;
var result:Object = ExternalInterface.call("getTextFromFlash");
//writes in the inputtext what it receives from JavaScript
resultado.text = result.toString();
switch (result.toString()) {
case ("1") :
gotoAndStop("2");
case ("2") :
gotoAndStop("3");
}
stop();
--> and i have this in javascript:
function getTextFromFlash() {
return "1";
}
--> my problem is that when they communicate in the Inputtext apears - 1 - but the switch doesnt make a match. Also in IE 7 the text that apears is - undefined - so they don't communicate.
Can someone help me with this problem?? i already googled everything i could and found nothing that helped me.