how do i know its simple…i dunno but knowing me…its pretty stupid and probably right under my nose…
im studying AS3 (after a long hiatus and trying to get back to flash)
so im doing this small site to test myself and while declaring my buttons (code below) i get a 1099 error saying
TypeError: Error #1009: Cannot access a property or method of a null object reference.
at main_fla::MainTimeline/frame1()
i have no idea what this means.
heres ALL i have on frame one so far.
import flash.events.MouseEvent;
import flash.ui.Mouse;
import flash.net.URLRequest;
//MY BUTTON declarations. THEIR LISTENERS AND THEIR FUNCTIONS below.
aboutBtn.addEventListener(MouseEvent.CLICK,aboutbtn);
function aboutbtn(e:MouseEvent):void
{
gotoAndPlay("about");
}
contactBtn.addEventListener(MouseEvent.CLICK,contactbtn);
function contactbtn(e:MouseEvent):void
{
gotoAndPlay("contact");
}
portfolioBtn.addEventListener(MouseEvent.CLICK,portfoliobtn);
function portfoliobtn(e:MouseEvent):void
{
gotoAndPlay("portfolio");
}
homeBtn.addEventListener(MouseEvent.CLICK,homebtn);
function homebtn(e:MouseEvent):void
{
gotoAndPlay("home");
}
followMeBtn.addEventListener(MouseEvent.CLICK,followmebtn);
function followmebtn(e:MouseEvent):void
{
navigateToURL(new URLRequest("http://www.twitter.com/somdow"), "_blank");
}
// Btns in the port section.
port2ImgBtn.addEventListener(MouseEvent.CLICK,port2imgbtn);
function port2imgbtn(e:MouseEvent):void
{
trace("btn clicked");
}
port1ImgBtn.addEventListener(MouseEvent.CLICK,port1imgbtn);
function port1imgbtn(e:MouseEvent):void
{
trace("btn clicked lol");
}
any ideas??? im lost