28 Replies Latest reply on Nov 12, 2009 4:45 PM by kglad

    Slider bar not controlling the timeline?

    rowancavanagh Level 1

      I'm back again.. with yet another problem on the same project.

       

      This time I'm attempting to make a timeline, that should control what frame of a movie clip on the root timeline is displayed. So relevant to where the user slides the slider bar, the appropriate information will be displayed inside that movie clip.

       

      Now I really have NO idea where to start the coding that will attempt to convert the slider's location on its on slider bar, to what frame is shown on that movieclip.

       

      But here's what I've put inside the movie clip, on it's timeline:

      if (_parent.mc_timeline.ratio >= 0){
          gotoAndPlay("One");
      }
      else if (_parent.mc_timeline.ratio >= 33){
          gotoAndPlay("Two");
      }
      else if (_parent.mc_timeline.ratio >= 66){
          gotoAndPlay("Three");
      }
      else {
          gotoAndPlay("One");
      }

       

      Basically what I'm trying to get it to do is go to a certain frame label (ie, One, Two or Three) when it is at a certain point on the slider bar.

       

      I've got 2 little display boxes in there as well, that demonstrate that the slider bar does export some kind of information. I just need to then use that to control what frame is displayed in my content movie clip.

       

      I've attached the file, please have a look. I'm sure it'd be much easier to solve if you have a look.

       

      Any questions are more than welcome.