title: AS 3 Call function in parent from child movieclip
body: <p>I have a container swf called main.swf that loads child swf's into a container using the Loader class.</p>
  
  <p>In AS2 I could call functions of the main.swf container using </p>
  
  <pre><code>_root.someFunction();
  </code></pre>
  
  <p>Is AS3 I am having a problem how to do this.</p>
  
  <p>I have tried using:</p>
  
  <pre><code>MovieClip(root.parent.parent).someFunction();
  </code></pre>
  
  <p>(get root of child.swf, parent is loader, parent is main.swf)</p>
  
  <p>but this is coming up as null</p>
  
  <p>Is there any way to do this so that it does not throw an error in the child swf and works when loaded into main swf?</p>