# Preloader - if statement?

**URL:** https://forum.kirupa.com/t/preloader-if-statement/20546
**Category:** Uncategorized
**Created:** [May 10, 2003, 2:52am UTC](https://forum.kirupa.com/t/preloader-if-statement/20546 "2003-05-10T02:52:30Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![takashi0808](https://avatars.discourse-cdn.com/v4/letter/t/e9c0ed/32.png) [@takashi0808](https://forum.kirupa.com/u/takashi0808)
#### Post date: [May 10, 2003, 2:52am UTC](https://forum.kirupa.com/t/preloader-if-statement/20546/1 "2003-05-10T02:52:30Z")

</div>

Here is what I want to do.

I have a button with this action script.  
on (release) {  
label = “profile”;  
\_root.door.closedoor();  
}

and at the end of the “door” movie clip, I have this action script.

label = \_root.label;  
\_root.gotoAndStop(label);  
//I guess I put if statement here.  
this.gotoAndPlay(“open”);

So, after this, it goes to the label that is specified.  
When it goes there, there is an action to load another movie.

loadMovie(“profile.swf”, “loadprofile”);

Here, I want to put a preloader.  
I put the preloader in the movie that gets loaded, but it doesn’t look right.  
So I want to put the preloader before the door opens up.  
when the movie is loaded, I want the door to open up.  
"if profile.swf is being loaded, stop. when the profile.swf is loaded, this.gotoAndPlay(“open)”;  
if I describe, it is like this. (sorry, I don’t know anything about action script!!)

I attached a swf file.  
I couldn’t attach a .fla movie because it was too big. If you think you can help me, I will be happy to send the file to you.

thanks!!

---

<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: [May 10, 2003, 2:58pm UTC](https://forum.kirupa.com/t/preloader-if-statement/20546/2 "2003-05-10T14:58:16Z")

</div>

Hey!

I saw your fla, maybe im not understanding properley but to me it looks like its working fine.

If you want send over the fla or give me a link were i can download it from and ill have a look at it =)

So u want a preloader to show b4 the file loads right and while the doors are closed?  
Is that all?
