3 Replies Latest reply on Aug 7, 2007 1:19 PM by kglad

    help with MX 2004 error message

    posterboy
      i am unsure what syntax to use.

      this is the error message that Flash MX 2004 is giving me...

      Line 14: Expected a field name after '.' operator.
      this[item+"_btn"].this[item+"EnterFrame"] = function() {

      Here is the code (bold highlight) that is puzzling me...

      function endeavourBtn (item) {
      this[item+"_btn"].onRelease = function() {
      intro_pic_mc.onEnterFrame = this[item+"EnterFrame"];
      }
      }

      function endeavourFade (item) {
      this[item+"_btn"]. this[item+"EnterFrame"] = function() {
      this._alpha -= 8;
      if (this._alpha <= 0) {
      delete this.onEnterFrame;
      if (item=="landing") {
      _root.gotoAndPlay(2);
      } else if (item=="omdp") {
      _root.gotoAndPlay(3);
      } else if (item=="rollover") {
      _root.gotoAndPlay(4);
      } else if (item=="rollout") {
      _root.gotoAndPlay(5);
      } else if (item=="launch") {
      _root.gotoAndPlay(6);
      }
      }
      }
      }

      endeavourFade("landing")
      endeavourFade("omdp")
      endeavourFade("rollover")
      endeavourFade("rollout")
      endeavourFade("launch")