# ReferenceError: Error #1069?

**URL:** <https://forum.kirupa.com/t/referenceerror-error-1069/321445>\
**Category:** flash\
**Created:** [April 20, 2011, 2:24am UTC](https://forum.kirupa.com/t/referenceerror-error-1069/321445 "2011-04-20T02:24:47Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Varixable](https://avatars.discourse-cdn.com/v4/letter/v/eb9ed0/32.png) [@Varixable](https://forum.kirupa.com/u/Varixable)\
**Post date:** [April 20, 2011, 2:24am UTC](https://forum.kirupa.com/t/referenceerror-error-1069/321445/1 "2011-04-20T02:24:47Z")

</div>

Hey guys I’m completely new to flash and I’m building a website right now. I’m trying to get my buttons to function with my pages, but I keep getting this error, and nothing but a continuous loop of my pages content.

“ReferenceError: Error #1069: Property num not found on flash.text.TextField and there is no default value.  
at streetlightfinal\_fla::MainTimeline/onclk()”

What am I doing wrong? :eyeup:

Here’s my code.

```auto
stop();

function makebutton(mc:MovieClip, num:int):void{
    
    mc.addEventListener(MouseEvent.CLICK, onclk);
    mc.buttonMode=true;
    mc.num=num;
    
    }

    function onclk(e:MouseEvent):void{
        pages.gotoAndStop(e.target.num);
    }
    
    makebutton(home_btn,1);
    makebutton(bio_btn,2);
    makebutton(gallery_btn,3);
    makebutton(music_btn,4);

```
