Skip to main content
Participating Frequently
May 26, 2007
Question

How do a make a button go to the last frame of an swf file?

  • May 26, 2007
  • 2 replies
  • 420 views
but i don't want it to play the entire movie, just the last frame.

Much appreciated, thanks!

jane
This topic has been closed for replies.

2 replies

kglad
Community Expert
Community Expert
May 30, 2007
use your movieclip's instance name instead of myClip (in both spots).
Inspiring
May 26, 2007
You can use the _totalframes property of the MovieClip class. Something like
so:

myButton.onRelease = function(){
myClip.gotoAndStop(myClip._totalframes);
}


--
Dave -
Head Developer
http://www.blurredistinction.com
Adobe Community Expert
http://www.adobe.com/communities/experts/


janemigAuthor
Participating Frequently
May 30, 2007
thanks for your help!!

do i substitute MyClip with my swf file name? i guess the answer is no, because when i do, it doesn't work.

any suggestions?

thank you!
Known Participant
May 30, 2007
If you just name a label like "lastFrame" and call it using gotoAndStop ("lastFrame")? Could be..