A Flash Developer Resource Site

Results 1 to 3 of 3

Thread: timing

  1. #1


    How do you run function after so many seconds
    like if I had a button that would call a function, how would I make it work so the function works after a few seconds after the button is clicked?

  2. #2
    Senior Member jbum's Avatar
    Join Date
    Feb 2004
    Los Angeles
    See the sticky post at the top of this forum about setInterval() - that's what you're looking for.


    millisecondsToDelay = 4*1000; // 4 seconds

    myFutureFunction = function()
    // do future stuff here...

    ih = setInterval(myFutureFunction, millisecondsToDelay);

  3. #3
    thnx jbum

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Click Here to Expand Forum to Full Width

HTML5 Development Center