1 Reply Latest reply on Oct 10, 2006 10:41 PM by AnandMX

    Need help with button

    exodusfyre
      I have a delema

      I have a site I am working on that has 7 buttons all movie clips. What I am trying to do is make it so variable menu = "1" is set upon movie load and when that variable is set it makes it link to the last frame of button 1. So when you click on button two it needs to change the variable to "2". Then button one will go to the previous frame and use the rewinding script I used to make everything smooth.
      For some reason the code I am using will not work. Any help would be great. Since these are all movie clips and not the main movie I would prefer that they were done with instances rather than gotoAndPlay


      some of the script I have used is as follows

      Frame one of the movie
      main="1"
      to set the variable

      in the movie clip frame 1
      if (main=="1") {
      news_mc.gotoAndStop(30);
      }

      frame 30 in movie clip
      if (main == "1") {
      news_mc.gotoAndStop(30);
      } else {
      news_mc.gotoAndPlay(28);
      }

      For the next button
      bios_mc.onRelease = function() {
      this.gotoAndStop(30);
      main = "2"
      };


      I would think this would work, if you see something wrong please help