How to remove a function on the main timeline within a movie clip
How do you remove a function that is coded on a frame in the main timeline from within a movie clip? I tried this, but no dice:
infoGraphicDisparity.addEventListener(MouseEvent.CLICK, fl_ClickToGoToScene);
function fl_ClickToGoToScene(event:MouseEvent):void
{
parent.removeEventListener (Event.ENTER_FRAME, parent["enterFrameHandler"]);
MovieClip(this.root).gotoAndPlay("disparity");
}
this is the event I am trying to remove:
stage.addEventListener(Event.ENTER_FRAME, enterFrameHandler);
any help would be appreciated as always.
Thanks!