3 Replies Latest reply on May 24, 2006 10:40 AM by yachts99-2vTvY1

    cant seem to call an attached movie

      start_btn.onRelease = function(){
      startMenuHolder_mc.attachMovie("startMenu_mc", "startMenu_mc", 100);
      i cant call the startMenu_mc when i attach it like this. i can only call it when its outside of the onRelease function.

      startMenuHolder_mc.attachMovie("startMenu_mc", "startMenu_mc", getNextHighestDepth());
      also when i use the getNextHighestDepth() instead of defining a specific level it won't let me removeMovieClip

        • 1. Re: cant seem to call an attached movie
          startMenu_mc is not inside the button so you need to use a different path to reference it. Is startMenu_mc on the main timeline? If so use:
          start_btn.onRelease = function(){
          _root.startMenuHolder_mc.attachMovie("startMenu_mc", "startMenu_mc", 100);

          What's your code for the removeMovieClip()?
          • 2. Re: cant seem to call an attached movie
            dxc Level 1
            looks like putting _root in front didnt change anything. i think the problem is that startMenu_mc is not being defined until i click the start_btn. therefore when i try to make refernce to it it dosnt realize it exists. i dont think its a path problem because when i take it out of the onRelease function it works.

            here is how im removing it. it works if i define what depth to put it at and only breaks when i attach the mc using getNextHighestDepth() . also breaks if i swap depths.
            • 3. Re: cant seem to call an attached movie
              yachts99-2vTvY1 Level 2
              You are not trying to "reference" startMenu_mc! You are trying to reference startMenuHolder_mc, which should be available (be seen by) start_btn. Where exactly is startMenuHolder_mc in relation to start_btn and does it exist on the timeline before start_btn is initialised?

              Also trying putting "this" in front of getNextHighestDepth(), as in this.getNextHighest Depth().