3 Replies Latest reply on Dec 4, 2007 12:40 PM by kglad

    Error with code - why?

    douggler Level 1
      Hi all

      I have a simple function below which is passed a number as an argument. I use this argument as part of a line of code which tells 1one of four movieclips (instance names of 1, 2, 3 and 4) to move to a specific frame label, however it hasn't been working and I only found errors were being generated when I changed the line of code (you can see where I commented out my old line of code):

      function MoveToFrame(frm) {
      _global.kbc = frm;
      //_level0.picHolder_mc.frm.gotoAndStop("used");
      _level0.picHolder_mc.2.gotoAndStop("used"); // here i hard coded to see if it made a difference
      }

      The error I am getting is as follows:

      **Error** Symbol=textContent, layer=Layer 2, frame=1:Line 6: Syntax error.
      _level0.picHolder_mc.2.gotoAndStop("used");

      Why is there an error occuring and how do I rectify it?

      Thanks in advance.