# Preloader

**URL:** <https://forum.kirupa.com/t/preloader/238593>\
**Category:** Uncategorized\
**Created:** [September 12, 2007, 10:16pm UTC](https://forum.kirupa.com/t/preloader/238593 "2007-09-12T22:16:43Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![ovidio](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/ovidio/32/2379_2.png) [@ovidio](https://forum.kirupa.com/u/ovidio)\
**Post date:** [September 12, 2007, 10:16pm UTC](https://forum.kirupa.com/t/preloader/238593/1 "2007-09-12T22:16:43Z")

</div>

I made a simple preloader using getBytesLoaded() and getBytesTotal(), situated in the first scene of the .fla.

A lot of the content(photos and .swf clips) in the second scene is added at runtime so in the library I had to set their linkage properties to"Export for ActionScript" and “Export in the 1st frame”.

The problem is that when I test the whole thing, the preloader doesn’t work properly. When the preloader appears on stage, it’s already way above 50% downloaded. It acts as if the lines of actionscript in the first frame of the first scene don’t get executed until a lot of the content (set to be exported for action script in the first frame) gets downloaded.

How can I fix that?
