Copy link to clipboard
Copied
hello everyone, I tried to make an application with adobe animate but it still doesn't work. are you guys can perfect this code:
function onButton_85(e:MouseEvent):void
{
switch (input1.text)
{
case "sun" :
gotoAndPlay(15);
break;
case "moon":
gotoAndPlay(25);
break;
default:
gotoAndStop(46);
break;
}
}
I want to make an application for elementary students about the solar system. so when students enter keywords and click the search button, an animation will appear. I am using AS 3.
"input1" is the name of the input text and "button_85" is the name for the search button while "moon" and "sun" are examples of keywords to be searched for.
the problem is when i use this code there is no error code notification, but the search button doesn't work.
Copy link to clipboard
Copied
As always, use trace() statements to verify the value of input1.text and that the function is even being called.