# Preloader whoas

**URL:** https://forum.kirupa.com/t/preloader-whoas/76268
**Category:** flash
**Created:** [January 16, 2005, 8:05pm UTC](https://forum.kirupa.com/t/preloader-whoas/76268 "2005-01-16T20:05:27Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![d9085](https://avatars.discourse-cdn.com/v4/letter/d/58f4c7/32.png) [@d9085](https://forum.kirupa.com/u/d9085)
#### Post date: [January 16, 2005, 8:05pm UTC](https://forum.kirupa.com/t/preloader-whoas/76268/1 "2005-01-16T20:05:27Z")

</div>

On Scene 1:  
I’ve imported 6 pictures to 6 different frames.  
Named the Frames p1, p2, p3 etc.  
I’ve a Button that takes me to the next frame  
I have a Dynamic Text box on each frame with the variable named pg\_cntr  
The AS I have for each frame is:  
[COLOR=YellowGreen]stop ();  
pg\_cntr = \_currentframe[/COLOR]  
Everything works fine until I do my preloader on Scene 2  
Pressing Ctrl + Enter twice runs the preloader.  
The preloader works and the movie plays but the dynamic text box that should say “[COLOR=Blue]1[/COLOR]” reads “[COLOR=Blue]3[/COLOR]”.  
The AS for the preloader in Frame 1 is:  
[COLOR=YellowGreen]total\_bytes = \_root.getBytesTotal();  
loaded\_bytes = \_root.getBytesLoaded();  
remaining\_bytes = total\_bytes-loaded\_bytes;  
percent\_done = int((loaded\_bytes/total\_bytes)\*100);  
bar.gotoAndStop(percent\_done);  
ifFrameLoaded (“Scene 1”, 6) {  
gotoAndPlay (“Scene 1”, 1);  
}[/COLOR]  
The AS for Frame 2 is:  
[COLOR=YellowGreen]gotoAndPlay (1);[/COLOR]

Any suggestions???
