Skip to main content
Participant
September 12, 2023
Question

1120: Undefined Property Error even though I'm it's the correct instance name

  • September 12, 2023
  • 2 replies
  • 144 views
stop();
 
start_btn.addEventListener(MouseEvent.CLICK, playGame);
function playGame (event:MouseEvent): void {
gotoAndStop ("gameplay");
 
}
 
Here is the code that I made for a true or false game. So, there is a button named start_btn, and its showing the error. I don't know how to move forward when I double-checked the instance name many times.
    This topic has been closed for replies.

    2 replies

    kglad
    Community Expert
    Community Expert
    September 12, 2023

    copy your code name and paste into the instance name field of the object that must exist when that code executes.

    JoãoCésar17023019
    Community Expert
    Community Expert
    September 12, 2023

    Hi.

     

    Can you show a picture of your instance selected on stage along with the Properties panel open?

     

    Regards,

    JC