# Going back from loaded swf

**URL:** <https://forum.kirupa.com/t/going-back-from-loaded-swf/278647>\
**Category:** flash\
**Created:** [January 3, 2009, 2:42am UTC](https://forum.kirupa.com/t/going-back-from-loaded-swf/278647 "2009-01-03T02:42:35Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![allex36](https://avatars.discourse-cdn.com/v4/letter/a/9dc877/32.png) [@allex36](https://forum.kirupa.com/u/allex36)\
**Post date:** [January 3, 2009, 2:42am UTC](https://forum.kirupa.com/t/going-back-from-loaded-swf/278647/1 "2009-01-03T02:42:35Z")

</div>

Hi , i posted something earlier but it looks like my post was too complex and long so i made a second version of it using shorter example:

I have a loaded .swf menu. This menu is loaded in my Main file on the first frame.  
I load it inside a [COLOR=#0000ff]MovieClip [/COLOR]called [COLOR=seagreen]“mastermc” [/COLOR][COLOR=black](I created this one by hand on the stage)[/COLOR]

i also create, within the script, a [COLOR=blue]MovieClip[/COLOR][COLOR=blue] [/COLOR]called [COLOR=seagreen]“vidmc”[/COLOR] , and place it using the  
[COLOR=blue]AddChildAt [/COLOR], so i make sure it is UNDER the menu (which is put on an upper level using the same function) Thus:

mastermc.[COLOR=blue]addChildAt/COLOR; // \<----- my background  
mastermc.[COLOR=blue]addChildAt/COLOR;  
mastermc.[COLOR=blue]addChildAt/COLOR;

i have a .as file that contains a function called [COLOR=seagreen]“addvideo”[/COLOR] that will play a .flv file in the [COLOR=#0000ff][COLOR=#2e8b57]“vidmc” [/COLOR]MovieClip [/COLOR]that is given in the parameters as reference.

Problem:

I am trying to call (from the button in my menu.swf) the [COLOR=seagreen]“addvideo”[/COLOR] function putting in the parameters “vidmc” which is a [COLOR=blue]MovieClip[/COLOR] located inside [COLOR=#2e8b57]“mastermc”[/COLOR] which is on the stage of my main file.

So this is the code in my menu.swf in the button. (It is a movieclip containing a button).

```auto
 
var par:MovieClip = MovieClip(this.parent.mastermc.vidclip);
 
function JabDfn(event:MouseEvent):void
{
 gotoAndStop(1);
 var newclass:technotest = new technotest;
 newclass.addvideo(par, "Jab", "toto.mp3");
}

```

It doesnt work. Of course it gives me an error when i start publish my menu.swf because it doesn’t even know there is another movieclip called mastermc and vidmc because they’re in the other .swf file.
