4 Replies Latest reply on Mar 7, 2008 1:21 PM by clbeech

    I wonder how come

    Walloompoom Level 1
      The trace returns exactly what I want but it doesn't work in the tween... I wonder how come.
        • 1. Re: I wonder how come
          i_am_captivate Level 1
          Have you imported the Tween class files?

          Make sure this is at the top of your code....

          import mx.transitions.Tween;
          import mx.transitions.easing.*;


          • 2. Re: I wonder how come
            clbeech Level 3
            the square brackets are used as 'access operators' and in the code above you do not have an indication as to 'what' property array is being accessed.

            assuming that the two variables are Strings, and that they are located at the root level, you may want to try:

            • 3. Re: I wonder how come
              Walloompoom Level 1
              Well, again, trace([path+btnOn]); returns what I need. The path to the movieclip I want to tween. But, why doesn't it work inside the tween?

              var tw3:Tween = new Tween(_root.mainMc.navMc.navL[btnOn], "_xscale", Back.easeOut, 115, 100, 0.3, true);

              the above works fine.
              btw, trace has the following output: _root.mainMc.navMc.nav.lb2
              • 4. Re: I wonder how come
                clbeech Level 3
                if the handler above is on the main timeline, remove '_root' from the 'path' var.

                If it is not on the main timeline, still remove the _root in 'path' but call to the _root in the Tween as in: