# Actionscript 3 - Error #1009 - simple button problem, please help

**URL:** <https://forum.kirupa.com/t/actionscript-3-error-1009-simple-button-problem-please-help/316810>\
**Category:** flash\
**Created:** [December 2, 2010, 10:17pm UTC](https://forum.kirupa.com/t/actionscript-3-error-1009-simple-button-problem-please-help/316810 "2010-12-02T22:17:59Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![whenurstrange](https://avatars.discourse-cdn.com/v4/letter/w/a587f6/32.png) [@whenurstrange](https://forum.kirupa.com/u/whenurstrange)\
**Post date:** [December 2, 2010, 10:17pm UTC](https://forum.kirupa.com/t/actionscript-3-error-1009-simple-button-problem-please-help/316810/1 "2010-12-02T22:17:59Z")

</div>

_“Error #1009: Cannot access a property or method of a null object reference”_

This is what I get every time I test the movie. All I’m trying to do is simply have a replay button at the end of my movieclip.

This is my code:

playBtn.addEventListener(MouseEvent.CLICK, fl\_ClickToGoToAndPlayFromFrame\_581);

function fl\_ClickToGoToAndPlayFromFrame\_581(event:MouseEvent):void  
{  
animationXmas.gotoAndPlay(1);  
}

I’m slowly going insane. Someone make sense of this please!
