# rollOver flash movie



## Gordian (Aug 25, 2004)

Hi, I'm searching for some different ways to run a flash movie as a button. The movie starts out with an image, and then fades into some text, nothing fancy . The problem is flash isn't letting me use the on() event handler. I'm clueless as to how I could use 
object.eventMethod = function () because I don't know if object.rollOver even works, and if it does, do I have to do something to the timeline in flash (add frame labels, put in stop functions, etc.) I've searched through google for some ideas, but I'm still too new to flash to understand any of it, and I only have a few days to get a site up and running with these rollOvers. If someone could help me through the steps It would be truly appreciated, Thanks.


----------



## covert215 (Apr 22, 2006)

Simply create a button symbol in flash. The button symbol has 4 frames, Up, Down, Over, and Hit.

Be sure to put a keyframe in each frame.

Up- What you see when the button is up
Down- What you see when the button is clicked on
Over- What you see when the mouse rolls over the button
Hit- This frame cannot be seen. Simply fill in the area that you want the button to be clickable.


----------



## covert215 (Apr 22, 2006)

Some other things:

The on() handler will only work with button symbols. The code must be applied to the button, not the stage.

Your whole flash file should be 1 frame with the button placed on it.

If you want to create animation within a specific stage of the button, use a movieclip symbol. Animate within the movieclip and place that in the button.


----------



## Gordian (Aug 25, 2004)

There seems to be a problem. since this is my first button, it is most definitely my fault, but when I test the button, the rollover doesn't work, but it does show the different pictures when i loop it. I put the movie file in the "over" frame and added in the pictures im using into the up frame, hit and down frame. Its not just the test movie area, when i put it on a blank webpage the same thing happens. Any solutions?
P.S. thanks for quick reply!


----------

