0 Replies Latest reply: May 21, 2014 12:11 PM by fefekobernik RSS

    Flash Action Script 3 is giving me 1120 error help please!

    fefekobernik Community Member

      I am having trouble coding this tutorial. I have changed it a little to fit my photos. I am getting this error 1120 below:

       

      Scene 1, Layer 'actions', Frame 1, Line 1    1120: Access of undefined property btn1.

      Scene 1, Layer 'actions', Frame 1, Line 2    1120: Access of undefined property btn2.

      Scene 1, Layer 'actions', Frame 1, Line 3    1120: Access of undefined property btn3.

      Scene 1, Layer 'actions', Frame 1, Line 4    1120: Access of undefined property btn4.

       

      I don't really understand the coding and need help fixing this problem. I believe their code is wrong because my gallery will not work from the tutorial.

      The code I have is below:

       

      stop(); btn1.addEventListener(MouseEvent.CLICK,play1); function play1(event:MouseEvent):void{ gotoAndStop ("rosie") }

        btn2.addEventListener(MouseEvent.CLICK,play2); function play2(event:MouseEvent):void{ gotoAndStop ("mel") }

        btn3.addEventListener(MouseEvent.CLICK,play3); function play3(event:MouseEvent):void{ gotoAndStop ("liz") }

        btn4.addEventListener(MouseEvent.CLICK,play4); function play4(event:MouseEvent):void{ gotoAndStop("kayla") } ;

       

      The code that was given to me is below: (Source:How to create a simple image gallery in flash cs5) :

       

        stop(); btn1.addEventListener(MouseEvent.CLICK,play1); function play1(event:MouseEvent):void{ gotoAndStop ("young") } btn2.addEventListener(MouseEvent.CLICK,play2); function play2(event:MouseEvent):void{ gotoAndStop ("thoughtful") } btn3.addEventListener(MouseEvent.CLICK,play3); function play3(event:MouseEvent):void{ gotoAndStop ("dancing") } btn4.addEventListener(MouseEvent.CLICK,play4); function play4(event:MouseEvent):void{ gotoAndStop ("old") }


      Can anyone help me with this tutorial or coding! That would be great. Thanks!!