# Issue with some external swf AS

**URL:** <https://forum.kirupa.com/t/issue-with-some-external-swf-as/141185>\
**Category:** Uncategorized\
**Created:** [March 17, 2005, 3:51pm UTC](https://forum.kirupa.com/t/issue-with-some-external-swf-as/141185 "2005-03-17T15:51:17Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![ultraloveninja](https://avatars.discourse-cdn.com/v4/letter/u/71e660/32.png) [@ultraloveninja](https://forum.kirupa.com/u/ultraloveninja)\
**Post date:** [March 17, 2005, 3:51pm UTC](https://forum.kirupa.com/t/issue-with-some-external-swf-as/141185/1 "2005-03-17T15:51:17Z")

</div>

i have a section in my flash animation that when a button is pressed, it transtitions from one extrenal swf to another. i used a tutorial from here.

the problem is that, when i press another button, the first external swf that is loaded, plays instead of the second one.

this is what i am doing:

i have some external swfs set up that animate here is the code that i use for them:

> 

\_root.pcontainer.loadMovie(\_root.currMovie+“.swf”)

that is on the last frame of the external swf.

now, i have some buttons that are nested inside a movie clip that operate the external swfs. here is the AS that i am using for those:

> 

on (release) {  
if (\_root.currMovie == undefined) {  
\_root.currMovie = “cramer”;  
pcontainer.loadMovie(“cramer.swf”);  
} else if (\_root.currMovie != “cramer”) {  
if (pcontainer.\_currentframe \>= pcontainer.midframe) {  
\_root.currMovie = “cramer”;  
pcontainer.play();  
}  
}  
}

also, i have a frame script that calls up the first selection:

> 

\_root.currMovie = “cramer”;  
pcontainer.loadMovie(\_root.currMovie+“.swf”);  
stop();

i’m not sure what the problem is. i’ve recreated this in a new movie, and it works. i’m thinking that it has something to do with the way that i need to label my MC within the AS, but i’m not sure on how or where to put it.
