First time here? First time here? Newsletter Signup Newsletter
Login | Register | 651326 Members and growing!
Search tutorials
Author: Dan Ludwig | Website:

Now let's add another scroll feature that allows the user to jump to either the top or the bottom of var_mc, by double-clicking one of the scroll buttons. I have done a little editing to the code that Mick originally sent me, but again, this is his concept. I'll try to explain it as best as I can:

A lot of the code here should look familiar, since the "gotoAnd" actions all work to create the continuous feedback button scrolling functionality. What should stick out is the "getTimer" action, the "if / else" parameters & actions, and the "last_click = first_click" expression. OK, now take a deep breath; and let's tackle"getTimer" first.

up_first_click = getTimer( );

Flash's internal Timer function begins counting upward in milliseconds (ms) as soon as an SWF file begins to load. The "getTimer" action can capture values, in milliseconds, for use in ActionScripts. The above expression sets the variable up_first_click to the Timer value when the top scroll button is clicked. After "getTimer" assigns a numerical value to up_first_click, Flash moves to the third line of code, the "if" clause.

» Level Intermediate

Added: 2000-12-08
Rating: 8 Votes: 94
(10 being the highest)
» Author
Me Like Flash 5. Flash 4 good. Flash 5 better.
» Download
Download the files used in this tutorial.
» Forums
More help? Search our boards for quick answers!


  • There are no comments yet. Be the first to comment!

  • You must have javascript enabled in order to post comments.

Leave a Comment
  • Your email address will not be published. All fields are required.
Featured Flash FLA
» Author: work2survive
» Title: Girl Walking 1kb
» Description: Walking girl, animation just takes 1kb, using high heels shoes, and fashion model attitude.
Featured Sound Loops
Image for equalize

Audio Player

» Author: BoxCat
» Title: CPU Talk
» Description: From the cyberpunk RPG, "Nameless: the Hackers" Completely Free to use! Keywords: edm hip hop rap electronic mysterious mission hacking chase exciting spy ios ambient chilling love happy sad angry suspense
Latest Font
» Author: Fábio FAFERS
» Description: I created this font for free use. Everyone can apply it in personal or business texts. Its free, but I want to be communicated in case of business use. Donations are accepted to keep the project of free fonts alive! Thank you all
Featured Sound Fx
Image for equalize

Audio Player

» Author: nathan
» Description:

A recorded sound of the Dimensional Fork Gate.