Load external SWF on top on another

I have a main screen swf and a button which brings out an external swf using the loadMovie() function.

This works fine. But how can I have a button which only closes the external swf but not the main screen swf? What function should I use or how I can achieve that?

It’s like an layer which just sits on top of the main swf. How can I close just the top layer?

You could use the [font=courier new]MovieClip.unloadMovie()[/font] method.

Example:

// load movie.swf into my_mc
my_mc.loadMovie("movie.swf");
// unload the contents of my_mc
my_mc.unloadMovie();