Error 1120: Access of Undefined Property
I was using flash when I received an error prompt saying: Error 1120:
Access of Undefined Property "InstanceName"; however, from experience, nothing seems to be wrong with my settings.
The settings (as seen on the screenshot I posted) are as follows:
-Instance name: "back1" (note that the action and the instance exist on a single frame)
-Actions:
stop();
back1.addEventListener(MouseEvent.CLICK, goback);
function goback(e:MouseEvent):void
{
play();
}
-Error:
Scene 1, Layer 'Actions', Frame 11, Line 3 1120: Access of Undefined Property back1
I believe it should run properly in because the following seem to be in order:
1. Instance name properties and script are both correctly spelled.
2. The instance and the actions exist on the same single frame.
3. The instance is placed directly on the stage, and not nested in another.
4. Due to the command "stop ();” the timeline stops at the set frame until a new command is entered. Therefore,the script has unrestricted access to the instance.
If this is correct then what is the reason behind this error message?
Thanks a lot for any help on this matter.