# Forced Preloader

**URL:** https://forum.kirupa.com/t/forced-preloader/120589
**Category:** Uncategorized
**Created:** [August 25, 2004, 4:56pm UTC](https://forum.kirupa.com/t/forced-preloader/120589 "2004-08-25T16:56:43Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![fatnslow](https://avatars.discourse-cdn.com/v4/letter/f/7993a0/32.png) [@fatnslow](https://forum.kirupa.com/u/fatnslow)
#### Post date: [August 25, 2004, 4:56pm UTC](https://forum.kirupa.com/t/forced-preloader/120589/1 "2004-08-25T16:56:43Z")

</div>

hey, I wonderd if anyone could help me make a forced preloader? My site is small so the preloader would just show up for one second and then go to the site, but i want it to go from 1 to 100, without going like 20 to 80 then done…

Can anyone help? I’ll be very gratefull. My preloader bar will have a width of 200.

Thanks,  
fatnslow

---

<div class="post-metadata">

### Author: ![stringy](https://avatars.discourse-cdn.com/v4/letter/s/919ad9/32.png) [@stringy](https://forum.kirupa.com/u/stringy)
#### Post date: [August 25, 2004, 8:31pm UTC](https://forum.kirupa.com/t/forced-preloader/120589/2 "2004-08-25T20:31:08Z")

</div>

> [@fatnslow](#):
>
> hey, I wonderd if anyone could help me make a forced preloader? My site is small so the preloader would just show up for one second and then go to the site, but i want it to go from 1 to 100, without going like 20 to 80 then done…
> 
> Can anyone help? I’ll be very gratefull. My preloader bar will have a width of 200.
> 
> Thanks,  
> fatnslow

lol  
textfield instance name myText  
bar instance name bar  
first frame  
stop();  
bar.\_width = 0;  
myfunction = function () {  
percent += 1;  
bar.\_width += 2;  
myText.text = percent+" % Loaded";  
if (percent == 100) {  
clearInterval(myInterval);  
gotoAndStop(2);  
}  
};  
myInterval = setInterval(myfunction, 100);

you can change 100 to adjust the speed
