Link to home
Start Free TrialLog in
Avatar of jvosika
jvosika

asked on

Flash Slide Presentations: Make slide advance after x seconds

I have been messing with the new slide screens feature in 2004 MX Pro and I was wondering if there was a way to automatically advance slides, I couldnt figure out a way except with mouse clicks...

Thanks!
Avatar of muso120999
muso120999

You can use setInterval:

function advanceSlide = function() {
    clearInterval(_root.id);
    // code to advance to next slide
    Slide.gotoNextSlide();
}

_root.id = setInterval(advanceSlide,3000); // wait 3 seconds before calling advanceSlide
Avatar of jvosika

ASKER

That threw an error, here is the output:

**Error** Screen=search:Line 10: '(' expected
     function advanceSlide = function() {

**Error** Screen=search:Line 16: Statement must appear within on/onClipEvent handler
     _root.id = setInterval(advanceSlide,3000); // wait 3 seconds before calling advanceSlide

Total ActionScript Errors: 2        Reported Errors: 2


Any ideas?
ASKER CERTIFIED SOLUTION
Avatar of muso120999
muso120999

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Are you still getting errors?
Avatar of jvosika

ASKER

I had to do some checking but here is the final code that is needed to work:

on(reveal) {
advanceSlide = function ()
{
currentSlide.gotoNextSlide();
}
setInterval(advanceSlide, 5000)
}


Thanks.