In your event handler (dispModule in your example code), event.target will 
reference the IModuleInfo returned from your getModule(...) call. Use that to 
identify the module loaded.

One additional caveat though: I'd highly recommend keeping a reference to the 
IModuleInfo returned from getModule until at least the module has loaded or 
failed to load. I've had numerous occasions where I didn't keep hold of the 
reference, called load() and then got nothing ... no READY or ERROR events 
getting fired. Presumably because it got GC'd.

--- In [email protected], "criptopus" <sd_br...@...> wrote:
>
> When I load a module...
> 
> private function loadModule(modName:String):void
> {
> module=ModuleManager.getModule("comps/InstCntr/" + modName + ".swf");
> module.addEventListener(ModuleEvent.READY, dispModule);
> module.load();
> }
> 
> How does my listener (dispModule) decide what has been loaded
> Is their an AysyncToken or somthing?
> 
> - Stephen
>


Reply via email to