• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint

16.3. Adding Scripts to Buttons

In Flash 5, button code is attached directly to button objects on stage. For example, in Flash 5, if we want the clicking of a button to advance the playhead of a movie to a frame labeled section1, we attach the following code to that button:

on (release) {
  gotoAndStop("section1");
}


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint