Hi
   i have 2 prts, the first loa the module the seconds removes 

loading

                         if (_myModuleLoaderLesson != null) {

                                _myModuleLesson = null;
                        }
                        _myModuleLoaderLesson = 
ModuleManager.getModule('com/peach/uofs/lesson/ModuleLesson.swf');
                        
_myModuleLoaderLesson.addEventListener(ModuleEvent.READY, onModuleReadyLesson);
                        _myModuleLoaderLesson.load(null, null, null, 
this.moduleFactory);


----------------  function to handler the Add Event Listner 


                private function onModuleReadyLesson(e:ModuleEvent):void {
                        _myModuleLesson = 
_myModuleLoaderLesson.factory.create() as Module;
                        this.addElement(_myModuleLesson);
                }


-------------------------

Removal


if (_myModuleLoaderLesson) {  // if myModuleLoder is null then no module to 
unload
                                _myModuleLoaderLesson.unload();

                                try {
                                        this.removeElement(_myModuleLesson);

                                }
                                catch (error:Error) {
                                        // do nother this is becuse theye clicn 
2 time on home button
                                }

                        }


________________________________________
From: jfb [[email protected]]
Sent: Friday, April 24, 2015 2:27 PM
To: [email protected]
Subject: Re: Help with modules

Thanks for your reply and help.
Anyone have a code in how to work with SWFLoader programmatically?
Best,



--
View this message in context: 
http://apache-flex-users.2333346.n4.nabble.com/Help-with-modules-tp10161p10168.html
Sent from the Apache Flex Users mailing list archive at Nabble.com.

Disclaimer: This electronic mail and any attachments are confidential and may 
be privileged. If you are not the intended recipient, please notify the sender 
immediately by replying to this email, and destroy all copies of this email and 
any attachments. Thank you. 

Reply via email to