How can i add timing to this code?

Hi,

In the tutorial named “How to load random movies” it loads random movies when the page refreshes. I want to modify the code to load random movies 5 seconds at a time.

This is the code from the tutorial, how can i add the property I wanted.


[COLOR=#000050]filename[/COLOR] [COLOR=#0000ff]=[/COLOR] [COLOR=#0000ff][[/COLOR][COLOR=#666666]"circular.swf"[/COLOR], [COLOR=#666666]"vibration.swf"[/COLOR], [COLOR=#666666]"random_movement.swf"[/COLOR][COLOR=#0000ff]][/COLOR]; [COLOR=#000050]path[/COLOR] [COLOR=#0000ff]=[/COLOR] [COLOR=#666666]"http://www.kirupa.com/developer/actionscript/animation/"[/COLOR]; [COLOR=#000050]i[/COLOR] [COLOR=#0000ff]=[/COLOR] [COLOR=#000050]filename[/COLOR].[COLOR=#0000d0]length[/COLOR]; [COLOR=#000050]k[/COLOR] [COLOR=#0000ff]=[/COLOR] [COLOR=#0000d0]Math[/COLOR].[COLOR=#0000d0]floor[/COLOR][COLOR=#0000ff]([/COLOR][COLOR=#0000d0]Math[/COLOR].[COLOR=#0000d0]random[/COLOR][COLOR=#0000ff]()*[/COLOR][COLOR=#000050]i[/COLOR][COLOR=#0000ff])[/COLOR]; [COLOR=#0000d0]loadMovie[/COLOR][COLOR=#0000ff]([/COLOR][COLOR=#000050]path[/COLOR][COLOR=#0000ff]+[/COLOR][COLOR=#000050]filename[/COLOR][COLOR=#0000ff][[/COLOR][COLOR=#000050]k[/COLOR][COLOR=#0000ff]][/COLOR], [COLOR=#000050]movieTarget[/COLOR][COLOR=#0000ff])[/COLOR]; 

Any help will be great.