0 Replies Latest reply on May 30, 2006 8:46 AM by cf_apprentice

    dynamic text and attachMovie

    cf_apprentice
      OK here is my function

      This works to produce a simple text effect. The problem arises when I try to use it multiple times. The variable "theText" either is written twice (I only get one string twice on the screen) or the two get mixed together( half of on "theText" and part of the last function calls "theText". I need to be able to use the effect more than once throughout a linear animation. Can anyone please help solve this. I have a deadline and I am obviously out of my league.

      speed = 50;
      i=1;

      function newText1(theText,space,initX,initY) {
      if(i<theText.length+1) {
      thisLetter = theText.substring(i-1,i);
      textMovies = attachMovie("textBox","textBox"+i,i);
      textMovies._x = textMovies._x + initX
      textMovies._x = textMovies._x + initX +(space * i);
      textMovies._y = initY;
      textMovies.theText = thisLetter;
      ++i;
      } else {
      trace("Interval Cleared");
      clearInterval(intevalID);
      }
      }
      intevalID = setInterval(newText1,speed,"test?",12,5,60);