4 Replies Latest reply on Aug 12, 2008 4:19 PM by kglad

    Path not working - removeMovieClip

    vin-E
      Hey all,

      I am on/off again flash developer, so maybe I am overlooking something simple. I have what should be a super simple problem. But it has taken 2 days now. I am stumped.

      I have a main shell .swf (_root). It loads a bunch of small .swf's. One is Menu.swf (_level20)and the other is Artist.swf (_level21). Menu is the main menus system, Artist is just one of the pages.

      Inside of Artist.swf, I have a button that creates an MC and opens another .swf using the code

      this.createEmptyMovieClip("Pop_Up", getNextHighestDepth());
      loadMovie("Artist1_Bio.swf", Pop_Up);

      In debugger it is _level21/Pop_Up. I want the main menu to be able to close this Pop_Up when I leave this section. I have tried every conceivable combination of:

      Pop_Up.removeMovieClip();
      removeMovieClip(Pop_Up);
      removeMovieClip(_level21.Pop_Up);
      _level21.Pop_Up.removeMovieClip();
      _level21.removeMovieClip(Pop_Up);
      unloadMovie(_level21.Pop_Up);
      unloadMovie(Pop_Up);
      _level21.unloadMovie(Pop_Up);
      _level21.Pop_Up.unloadMovie();

      None of them work. BUT, inside of the Pop_Up MC I can put a simple removeMovieClip(_parent.Pop_Up); and it works.

      But I need to to work from the menu items, as I do not want to leave thsi page without removing the pop_ups.

      I have even tried using a function at the root level. No luck.

      Any thoughts?

      -vince