# Convert my script into something more useful

**URL:** <https://forum.kirupa.com/t/convert-my-script-into-something-more-useful/268073>\
**Category:** Uncategorized\
**Created:** [August 8, 2008, 9:17pm UTC](https://forum.kirupa.com/t/convert-my-script-into-something-more-useful/268073 "2008-08-08T21:17:38Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Kalani](https://avatars.discourse-cdn.com/v4/letter/k/8e8cbc/32.png) [@Kalani](https://forum.kirupa.com/u/Kalani)\
**Post date:** [August 8, 2008, 9:17pm UTC](https://forum.kirupa.com/t/convert-my-script-into-something-more-useful/268073/1 "2008-08-08T21:17:38Z")

</div>

I am not an actionscript guru by any means but I know the basics.

I would appreciate if someone could point me in the right direction. I like this example:  
[http://www.signaturemazda.com](http://www.signaturemazda.com)

The flash movie pulls in one random image and when the page is refreshed it shows another.

I have a script here that loads a jpg on refresh but not into a movie clip. It also is limited to cycling through a predetermined amount of images. I would like it to just load whatever images are in the folder or directory.

This is what I have.

```auto
var myImageSequence = 3;
var myRandomNumber = Math.floor(Math.random()*myImageSequence)+1;
var myImageName = myRandomNumber + ".jpg";
loadMovieNum(myImageName, 1);

```

Could someone please lead me in the right direction or get me started…

Much appreciated.
