Alright, so I have these buttons that I want other animation to play when I rollOver and then again when I rollOut. I made a MC and named the instance. I have stop();s on frames 1 (empty), 15 and 30 (the last one). Here are my AS for the button:
on(rollOver){
tellTarget("/song1ani"){
gotoAndPlay(2);
}
}
on(rollOut){
tellTarget("/song1ani"){
gotoAndPlay(16);
}
}
Here’s the clincher!! It works fine, but when I hit Ctrl+Enter to test the movie; the output window tells me that the stop(); on frame 15 needs an onClipEvent handler.
Of course, I gave it one and made everything worse.
Should I ignore the output window? Cause it works fine. Just figured I’d ask.
Thanks!!
Symbol=song1tell, Layer=Layer1, Frame=15: Line 1: Statement must appear within on/onClipEvent handler
stop();
So I finished the other tellTargets the same way and now two errors come up (same errors) but all five work - they’re identical. Is it becuase I’m using old code?
well it’s saying that there is a statment that needs to be in a event handler, but it’s definitely not the stop action. Try switching over to the new sintax like how I showed you above and see if the errors go away.
Ok after about 20 mins of going through your fla which is a complete jungle for me, I had no idea what was going on…ahhahah, I finally found the source of the error messages. Inside these 2 movieclips, you’ve accidently placed a stop action on the object inside that movieclip itself and so it caused the error to appear. The 2 movieclips are “Symbol 142” and “song1tell”. So just open your library find those movieclips, double click on them to open them up and go to each frame and select the object on each of those frames and make sure there isn’t a stop action placed on those objects. I noticed you have stop actions on the frames which are ok, but on the object on those frames, you have a stop on the object itself.
I tested it out and the errors are gone, I would post the file back but I don’t have room on my server right now. So go ahead and do that and let me know how it goes.
Rest assured, you didn’t confuse me. However what does confuse me is how I got those stops on the object…Hmm. Sorry it was so much of a mess; I’m still learning.
That worked! Thank you - I appreciate the time spent. The best part is now I can go to sleep!!
I’m glad you found the stops and got things working. You probably accidently placed them there while placing the stops on the frames, pretty common mistake. =)
Creating engaging and entertaining content for designers and developers since 1998.