Skip to main content
Known Participant
November 13, 2007
Question

Why error message?

  • November 13, 2007
  • 42 replies
  • 2873 views
I am attempting to learn to do in Flash some things I have typically done in Director. Needless to say, it's been a tough go. I have been using some of the Lynda.com stuff and it's been helpful, but I now have a problem I can't figure out. I am using a script that Lynda.com uses in their tutorial movies. I copied it (except using my names for things, of course) and from what I can tell, I did it correctly, but I keep getting an error message. Here is my action script (in it's own layer):

stop();

function onIntroClick(evt:MouseEvent):void {
gotoAndStop("intro");
}
introbut2jpg.addEventListener(MouseEvent.CLICK, onIntroClick);

It's just a graphic I turned into a button that should jump to the frame labeled "intro" and stop there. Works great in the tutorial, but I get:

Location: Scene = Scene 1, layer = Actions, frame=39, Line 3
Description: The class or interface 'MouseEvent' could not be loaded.
Source: function onIntroClick(evt:MouseEvent):void {
This topic has been closed for replies.

42 replies

kglad
Community Expert
Community Expert
November 13, 2007
change your publish settings (file/publish settings/flash) to actionscript 3.
eddiwill9Author
Known Participant
November 13, 2007
Got cut off:

I wonder if it's because I have the button swap out onmouseover? I tried the script with both button names (the normal state name as well as mouseover state name, but it didn't help).

I would greatly appreciate any help; I am SO close to actually completing this thing! :)