How to access parent variables and functions

/ Published in: ActionScript 3
Save to your folder(s)

(this.parent) can be altered depending on how far back you want to go. (this.parent.parent.parent) for example.

Copy this code and paste it in your HTML
  1. To access a parent variable: MovieClip(this.parent).variableName;
  3. To access a parent function: MovieClip(this.parent).functionName();

Report this snippet


RSS Icon Subscribe to comments

You need to login to post a comment.