Error code 1009 CS6

Help!

I'm trying to reorganize a flash for a Web site, but I'm stuck with the coding. I'm trying to link buttons to external URLS and I get the error code

TypeError: Error #1009: cannot access a property or method of a null object reference.

at Untitled_fla::MainTimeline/frame1()

I have the debug code and find the line that has a problem (the line of 'function' in the code), but I still don't understand. I used the code

news_btn.addEventListener (MouseEvent.CLICK, move1);

function move1(event:MouseEvent):void {}

var newsLink:URLRequest = new URLRequest ("http://www.powerquestglobal.com/news.htm");

navigateToURL (newsLink, "_self");

}

for the first button and it works fine. But when I copy and paste error 1009, replacing 'move1' in "move2" and by changing the adresse_web happens. Can someone help me? Please, I beg you!

My recommendation would be to twist your thinking/learning a whole little bit do not associate the library with the instance names names.  You may find yourself with the same object library several times in a drawing, so the name that means the most is the name of the instance.  It is the only name, that the code is going to care.  Everything that you name things in the library needs to be done to make it easier to find... other than that, the library names mean nothing.

You should not have code on every image on the layer actions for buttons.  If done correctly they should only need code in an image.

Tags: Adobe Animate

Similar Questions

Maybe you are looking for

  • Hi I have been looking at the PC and wondering what hp model is the best way to upgrade

    I have reflected on some hp machines and do not find with decent food that would support sli or xfire are all hp machines that have a way of evolution?

  • Time stamp incorrect TDMS?

    Whence the timestamp in the TDMS file format? I assumed it was the date and time system, but appears not to be the case. I have a vi that capture data, a few treatment and then saves some parameters using the PDM format. I've collected and saved 20 s

  • HP touch smart 15 t upgraded to 750 GB 240 GB ssd hard drive

    could you help me with this dilemma I have HP envy 15 TS or 15 t,.The specifications are:8.1 Windows 64• 4th generation Intel Core i7-4702MQ CPU• Dedicated NVIDIA GeForce GT 750 M with 4096 MB of video memory• diagonal 15.6-inch Full HD BrightView (1

  • How to differentiate the window system is using

    Hey,. How can I find out which Windows I use?

  • maskinvara enhet

    Hej! JAG har inloggning med Nordea E-kod-legitimacy... Vet inte hur jag ska bort ut kontakten efter anvandning.  Har inget dar det om utmatning star just av E-leg. Far upp att det saknas drivrutin. Vara DET kan just till denna eller hur jag gor. Ovri