Skip to main content
Participating Frequently
December 7, 2007
Question

I can't seem to get my flash site to work- Please help

  • December 7, 2007
  • 3 replies
  • 420 views
Good morning to all,
I am creating a site in Flash, I am using AS3 to create a site that stops/starts the movie on my home page and I have a series of buttons that play a head (or are supposed to) to the a frame for each additional page. Do I need A.S. for each button as well? I didn't think I did. The script below is the first one in the layer titled actions, this I thought is supposed to stop/start the movie at the beginning and the button abt_mgn_btn is supposed to bring it to frame 10 to play my about page. ?? at my frame number 10 should I put the stop(); script there as well? And at every frame break for the next pages? I am hopelessly in need of guidance. Thank you to anyone helping me out.

import flash.events.EventDispatcher;
import flash.display.MovieClip;
this.stop();

function startMovie(event:MouseEvent):void {
this.gotoAndPlay(10);
}
abt_mgn_btn.addEventListener(MouseEvent.click,startMovie);
This topic has been closed for replies.

3 replies

kglad
Community Expert
Community Expert
December 7, 2007
are you using a button component?
kglad
Community Expert
Community Expert
December 7, 2007
ok. fix that CLICK and retest.
cwfdesignAuthor
Participating Frequently
December 7, 2007
kglad,

I fixed that CLICK. I took out the import statements like you suggested. On the output I am getting this now-
TypeError: Error #1034: Type Coercion failed: cannot convert flash.display::MovieClip@1c53e6a1 to flash.display.SimpleButton.
at flash.display::Sprite/flash.display:Sprite::constructChildren()
at flash.display::Sprite$iinit()
at flash.display::MovieClip$iinit()
at site1_fla::MainTimeline$iinit()
Still the movie plays through and nothing action wise happens with the buttons.
I do still have to give the buttons a action right? But it is not letting me give them one. I do have them as buttons in every way.
kglad
Community Expert
Community Expert
December 7, 2007
case counts in actionscript: use MouseEvent.CLICK

and you must code each button. and there's no need for those import statements.
cwfdesignAuthor
Participating Frequently
December 7, 2007
Kglad,

I definitely want to learn how and do the work. I will take everything I have to learn this.