# Random background in flash with Action Script

**URL:** <https://forum.kirupa.com/t/random-background-in-flash-with-action-script/198679>\
**Category:** flash\
**Created:** [August 27, 2006, 5:48pm UTC](https://forum.kirupa.com/t/random-background-in-flash-with-action-script/198679 "2006-08-27T17:48:15Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![mattyshack](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/mattyshack/32/1559_2.png) [@mattyshack](https://forum.kirupa.com/u/mattyshack)\
**Post date:** [August 27, 2006, 5:48pm UTC](https://forum.kirupa.com/t/random-background-in-flash-with-action-script/198679/1 "2006-08-27T17:48:15Z")

</div>

Hey, I saw this tutrial on Kirupa

[http://www.kirupa.com/developer/mx/loadingrandombackground.htm](http://www.kirupa.com/developer/mx/loadingrandombackground.htm)

But what I want to do is pull in a random background png from a folder, and not embed each image in the actual flash movie. Obviously, I would rather load one image, than all 5 in a movie. Has anyone seen any AS code to do that? Thanks in advance.
