# Swf (pre)load

**URL:** https://forum.kirupa.com/t/swf-pre-load/17961
**Category:** Uncategorized
**Created:** [April 11, 2003, 1:20pm UTC](https://forum.kirupa.com/t/swf-pre-load/17961 "2003-04-11T13:20:04Z")
**Posts on this page:** 9
**Page:** 1

<div class="post-metadata">

### Author: ![thekok](https://avatars.discourse-cdn.com/v4/letter/t/9e8a1a/32.png) [@thekok](https://forum.kirupa.com/u/thekok)
#### Post date: [April 11, 2003, 1:20pm UTC](https://forum.kirupa.com/t/swf-pre-load/17961/1 "2003-04-11T13:20:04Z")

</div>

I need to speed up a website.  
This is the structure.

\_ Html page no swf inside , 99% broswer friendly( still have to decide how & when detect the plug –in )  
\_ Main.sfw within a Pop-up window  
in this main.swf i got 12 buttons which load 12 ext swf.  
Each swf with its personal preloader.and smaller than main(stage size)  
Every ext clip is around 100 / 200k that means { italian cables : ( } few second  
And when the user click on a button nothing happen for 3 sec than start the loading and than the clip. The impression after the first click is that nothink is about to start so ( if u are in rush ) u click again and again loading the same moving over and over.  
So till now i got 3 problem , not very clever buttons , ext swf to load as fast as i can and find some kind of smoothy way to make visible this site also for people that have to download the plug-in.  
I my sick mind i was thinking to put some preload ( in the browser cache !???)inside the main.swf after is all ( the main.swf around 400k ) loaded . i can not load all the swf at once ‘cause the user will be waiting x 2MB.so i was wondering if I can use the time while the user is thinking which button to press…………( too quick ??).  
I am lost.  
I already posted questions like that but i still need some clarification .  
Thanks for reading.

:bounce:

---

<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: [April 11, 2003, 1:58pm UTC](https://forum.kirupa.com/t/swf-pre-load/17961/2 "2003-04-11T13:58:55Z")

</div>

I’m sorry, I don’t understand what’s your problem exactly :-\ Do you know how to use loadMovie?

pom 🙂

---

<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: [April 11, 2003, 4:41pm UTC](https://forum.kirupa.com/t/swf-pre-load/17961/3 "2003-04-11T16:41:58Z")

</div>

all the external swf are loaded into the main swf by some button with the function loadmov & tell target .  
fine.  
My question is : there is a way to pre load into browser cache all the ext clip so once the user is clicking on a button asking x the movie the wait it won’t be so long. ?  
:hangover:

---

<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: [April 11, 2003, 5:02pm UTC](https://forum.kirupa.com/t/swf-pre-load/17961/4 "2003-04-11T17:02:27Z")

</div>

i´m sure Ilyas will come up with a better solution, but i´ll give it a try 😉

you can load the movies all at once, and set the visibility ([COLOR=blue]\_visible[/COLOR]) of the ‘to be loaded’ movies to [COLOR=blue]false[/COLOR], and then on the click of a button (the one that was loading the movie) you reset the visibility to [COLOR=blue]true[/COLOR].

---

<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: [April 11, 2003, 5:53pm UTC](https://forum.kirupa.com/t/swf-pre-load/17961/5 "2003-04-11T17:53:33Z")

</div>

it sound easy but i don’t know how to set the ( \_visible).  
at the moment the action on every button is  
on (release) {  
loadMovie(“ext.swf”, “my\_dummy”);  
}

---

<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: [April 11, 2003, 6:07pm UTC](https://forum.kirupa.com/t/swf-pre-load/17961/6 "2003-04-11T18:07:19Z")

</div>

Guig0’s solution is excellent. All you have to do is put all your “dummy” clips outside the scene, set the visibility to false (read the manual or search the forum a bit for that), and when you click a button, bring the clip where you want it and make it appear (\_visible=true).

pom 🙂

---

<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: [April 11, 2003, 6:17pm UTC](https://forum.kirupa.com/t/swf-pre-load/17961/7 "2003-04-11T18:17:58Z")

</div>

thanks i’ll try to do something .  
i don’t understand one thing.  
My dummy clip is just one, is empty and i use it to set the location where the external ( 12 ) swf will be showed.  
So what about the scene ?.  
sorry i am thick!

---

<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: [April 11, 2003, 6:21pm UTC](https://forum.kirupa.com/t/swf-pre-load/17961/8 "2003-04-11T18:21:47Z")

</div>

Simply use as many clips as movies you have to load. This is not a very clean solution though, and loading a section (in 1 “dummy” clip) when a user clicks a button might be a better solution.

---

<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: [April 11, 2003, 6:49pm UTC](https://forum.kirupa.com/t/swf-pre-load/17961/9 "2003-04-11T18:49:51Z")

</div>

i tryed your way 2 weeks ago and i had a problem.  
Was hard x me to deal with more movies in the same stage at the same moment.  
so i decided to put only one empty dummy in the main and make everything loading in there. I found this way easy, i do not have to use Unload movie and if the user want to see a different clip will click and the former movie will disappear.  
I would like use 12 empty dummy clip ( so i can load every singol clip in a different location because now are all registered with the same left top corner point…)  
ps do u think i can find any tutorial about the “visibility” linked to pre load movie.  
thanks  
goig to dinner back later…  
ps 2 i need upload a .fla ( not about this topi ) but zipped is 128k and it doesn’t goes by…
