PDA

View Full Version : FMX loadMovie and onMouseDown event



coreyem
July 18th, 2005, 02:27 PM
I've got a very simple movie clip that is supposed to load an external .swf into an empty clip that gets created when you click on one of the clip instances on the stage.

about_mc.onMouseDown = function(){
_root.createEmptyMovieClip("emailform_mc",this.getNextHighestDepth());
_root.emailform_mc._lockroot = true;
_root.emailform_mc.loadMovie("emailform.swf");
trace(_root.emailform_mc);
}

The empty movie clip gets created (I assume), and the .swf gets loaded in, but when you click anywhere on the stage, this code gets executed, basically loading the .swf back in. It's only supposed to execute when you click on "about_mc" . What am I missing, besides a brain?
-C

virusescu
July 18th, 2005, 02:48 PM
about_mc.onPress ;)
onMouseDown is an event generated by the Mouse object not by the mc like in the onPress onRelease case.

coreyem
July 18th, 2005, 03:08 PM
about_mc.onPress ;)
onMouseDown is an event generated by the Mouse object not by the mc like in the onPress onRelease case.

:sigh:
thanks man. I'll get the hang of this stuff one of these years...