# Making a Movie Clip display external .Swf

**URL:** <https://forum.kirupa.com/t/making-a-movie-clip-display-external-swf/65372>\
**Category:** flash\
**Created:** [September 25, 2004, 4:18pm UTC](https://forum.kirupa.com/t/making-a-movie-clip-display-external-swf/65372 "2004-09-25T16:18:36Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![chunk](https://avatars.discourse-cdn.com/v4/letter/c/ee59a6/32.png) [@chunk](https://forum.kirupa.com/u/chunk)\
**Post date:** [September 25, 2004, 4:18pm UTC](https://forum.kirupa.com/t/making-a-movie-clip-display-external-swf/65372/1 "2004-09-25T16:18:36Z")

</div>

Hello,

Ive got a movie clip named “resizeSquare”, when i click on a butten i would like this to resize and display an external swf, named, home.swf, and also the ability to ad more buttens to link to other things like links.swf.

This is my code so far:

> stageWidth=700;  
> stageHeight=400;  
> wmodifier = 300;  
> hmodifier = 150;  
> bouncefactor = .7;  
> speedfactor = 8;  
> expand = function (id) {  
> this.destwidth = wmodifier;  
> this.poswidth = id.\_width;  
> this.velwidth = this.velwidth_bouncefactor+(this.destwidth-this.poswidth)/speedfactor;  
> id.\_width += Math.round(this.velwidth);  
> this.destheight = hmodifier;  
> this.posheight = id.\_height;  
> this.velheight = this.velheight_bouncefactor+(this.destheight-this.posheight)/speedfactor;  
> id.\_height += Math.round(this.velheight);  
> this.destx = (stageWidth-wmodifier)/2;  
> this.posx = id.\_x;  
> this.velx = this.velx_bouncefactor+(this.destx-this.posx)/speedfactor;  
> id.\_x += Math.round(this.velx);  
> this.desty = (stageHeight-hmodifier)/2;  
> this.posy = id.\_y;  
> this.vely = this.vely_bouncefactor+(this.desty-this.posy)/speedfactor;  
> id.\_y += Math.round(this.vely);  
> resizeBG.\_width = (colorSquare.\_width+20);  
> resizeBG.\_x = (colorSquare.\_x-10);  
> resizeBG.\_height = (colorSquare.\_height+20);  
> resizeBG.\_y = (colorSquare.\_y-10);  
> };  
> resizeSquare.onEnterFrame = function() {  
> expand(this);  
> }; [QUOTE]

and my buttens have:

[QUOTE]on (press) {  
wmodifier=75;  
hmodifier=75;  
}

This all works, i just cant think of a way, to get the resizeSquare to load external .swfs, maybe:

on (press) {  
wmodifier=W of the swf;  
hmodifier=H of the swf;  
}

and then something like: tell target resize square load “/home.swf”

Thanks for reading this anyway.

---

<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:** [September 25, 2004, 5:00pm UTC](https://forum.kirupa.com/t/making-a-movie-clip-display-external-swf/65372/2 "2004-09-25T17:00:19Z")

</div>

Yeah that is what i’m looking into. right now i’m using the the resize gallery to see if that works. I get mix results. you should check it out its under best of kirupa.

[http://www.kirupaforum.com/forums/showthread.php?t=52290](http://www.kirupaforum.com/forums/showthread.php?t=52290)

If i work things out than i will post it. Good luck

---

<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:** [September 26, 2004, 6:55am UTC](https://forum.kirupa.com/t/making-a-movie-clip-display-external-swf/65372/3 "2004-09-26T06:55:51Z")

</div>

Thanks Gupps 😃
