# (how) preloader for external swf?

**URL:** https://forum.kirupa.com/t/how-preloader-for-external-swf/180381
**Category:** Uncategorized
**Created:** [February 28, 2006, 7:14am UTC](https://forum.kirupa.com/t/how-preloader-for-external-swf/180381 "2006-02-28T07:14:22Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![rightclick](https://avatars.discourse-cdn.com/v4/letter/r/8c91f0/32.png) [@rightclick](https://forum.kirupa.com/u/rightclick)
#### Post date: [February 28, 2006, 7:14am UTC](https://forum.kirupa.com/t/how-preloader-for-external-swf/180381/1 "2006-02-28T07:14:22Z")

</div>

Hi,

Im working on a full flash site that references other swf files into a target area, and Id like a preloader for these files - but have been unsuccessful…

(I am working from the [following tutorial](http://www.webwasp.co.uk/tutorials/b05-preload/index.php) as a reference for my preloader scripting btw.)

I can load swf’s just fine, but some are flv video files that wait in the dark before coming to screen, which probably would confuse users of the site… thus a preloader is needed.

Ive tried a number of things, including attaching the preloader to the external swf, but still with no luck.

my thumbnail code is the following (my thumbnails are a mc inside another mc)[INDENT][COLOR=SeaGreen]on(press) {  
gotoAndPlay(2);  
}[/COLOR][COLOR=DeepSkyBlue][COLOR=SeaGreen][COLOR=Black]  
[/COLOR][/COLOR][/COLOR][/INDENT][COLOR=DeepSkyBlue][COLOR=SeaGreen][COLOR=Black]and on frame 2…[/COLOR][/COLOR][/COLOR][INDENT][COLOR=DeepSkyBlue][COLOR=SeaGreen]myLoaded = Math.round(getBytesLoaded());  
myTotal = Math.round(getBytesTotal());  
myPercent = myLoaded/myTotal;  
myBar.\_width = myPercent_150;  
myText = Math.round(myPercent_100)+"%";  
if (myLoaded == myTotal) { [COLOR=Black]//preloader stuff[/COLOR]  
\_root.target1.loadMovie(“bus\_sequence.swf”);  
} else {  
gotoAndPlay(2); [COLOR=Black]//load external swf stuff[/COLOR]  
}[/COLOR][/COLOR]  
[/INDENT]code works fine separately, just not together…  
Any thoughts?
