# External preloader

**URL:** https://forum.kirupa.com/t/external-preloader/10317
**Category:** flash
**Created:** [December 29, 2002, 11:08am UTC](https://forum.kirupa.com/t/external-preloader/10317 "2002-12-29T11:08:23Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![kalimqvka](https://avatars.discourse-cdn.com/v4/letter/k/c2a13f/32.png) [@kalimqvka](https://forum.kirupa.com/u/kalimqvka)
#### Post date: [December 29, 2002, 11:08am UTC](https://forum.kirupa.com/t/external-preloader/10317/1 "2002-12-29T11:08:23Z")

</div>

I have a big MC to be loaded and when I try a normal preloader put on the first scene of the MC it just doesn’t start until the first frame of the MC is loaded.  
Flash is made up in a way that all the content of the MC is loaded on the first frame so my first frame is like 155 kb big.  
I found out I had to build an external preloader but I don’t know how?  
I found a tut on the subject but the MC there was loaded into a level.  
I want to ask if someone knows how to build a preloader to load a movie into a target.

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [December 29, 2002, 11:15am UTC](https://forum.kirupa.com/t/external-preloader/10317/2 "2002-12-29T11:15:26Z")

</div>

i did that using levels not targets, and i used \_level#.getBytesLoaded and \_level#.getBytesTotal instead of \_frameLoaded…

for levels, it works just the same way a normal preloader would work

heres the code i used

```php

onClipEvent(load){
loadMovieNum( _root.section, 1) // the variable section contains the address to the swf to be loaded
}
onClipEvent(enterFrame){
loadedbytes = _level1.getBytesLoaded()
total = _level1.getBytesTotal()
percentage = Math.round(rloaded*100/total)
per = percentage + "%"
bar._width = percentage
if (rloaded == total){
_parent.play()
}
}

```

cheers  
:A+: ![](http://www.flashdevils.com/~ahmed/hmed.gif)

---

<div class="post-metadata">

### Author: ![system](https://canada1.discourse-cdn.com/flex011/uploads/kirupa/original/3X/6/2/621e5c11736f46532526e61be85940af4230f3e5.png) [@system](https://forum.kirupa.com/u/system)
#### Post date: [December 29, 2002, 11:18am UTC](https://forum.kirupa.com/t/external-preloader/10317/3 "2002-12-29T11:18:21Z")

</div>

i think you can still load an swf into a target and use

```php

_root.movieclipName.getBytesLoaded

```

but i havent tried that yet… you might wanna give it a shot=)

cheers  
:A+: ![](http://www.flashdevils.com/~ahmed/hmed.gif)
