Hi Ben pls give me the link let me go through it may help, I also had problem with memory when i try to load movie into another because I still didn't get the logic of AS3 for load and unload.
On Tue, Jun 14, 2011 at 1:32 AM, Ben Sand <b...@bensand.com> wrote: > Looked into this a while ago. Bottom line was you can never guarantee > an unload, so repeated load/unload always have the potential for > memory leaks. > > In the case of Flex apps it was never possible to completely clear > them from memory. > > Our solution was to load other swfs in another window, though I > appreciate this won't suit everyone. It may be possibleto load them on > the same page with JavaScript communication between apps. If there is > a physical overlap between the display areas, eg using z-index of CSS > you may give up the option of 3d acceleration in flash 11 and there > may be issues with display on some operating systems/ browsers > > On my phone now, but I can give links if you're interested > > On Tuesday, 14 June 2011, Bassam M <sense...@gmail.com> wrote: > > hi guys > > I'm try to move from AS2 to AS3 I did some work with AS3 it seems to be > easy > > anyway i have problem with load and unload swf, in AS2 I use to use > > > > loadMovie("movie.swf",level) > > then from the movie.swf" I can use back button to load the main movie > again > > or unload the movie if the level more the 0 > > in AS3 I use code > > menu.movieBtn.addEventListener(MouseEvent.CLICK,loadMovieSwf); > > > > function loadMovieSwf(event:Event) > > { > > var requestURL:URLRequest = new URLRequest("movie.swf") > > var loader:Loader = new Loader() > > loader.load(requestURL) > > addChildAt(loader) > > > > } > > > > the problem I'm not able to unload movie from movie.swf I can unload > > movie.swf from the main movie by this code > > loader.unloadAndStop(); > > removeChild(_loader); > > loader= null; > > but if I place this code in movie.swf I get error > > it was easy to do it in AS2 just unloadMovie(level) > > I'm doing project with many swf files I have to load it from main page > and > > go back to main page I hope the problem is clear > > > > thank you > > Bassam > > _______________________________________________ > > Flashcoders mailing list > > Flashcoders@chattyfig.figleaf.com > > http://chattyfig.figleaf.com/mailman/listinfo/flashcoders > > > > _______________________________________________ > Flashcoders mailing list > Flashcoders@chattyfig.figleaf.com > http://chattyfig.figleaf.com/mailman/listinfo/flashcoders > _______________________________________________ Flashcoders mailing list Flashcoders@chattyfig.figleaf.com http://chattyfig.figleaf.com/mailman/listinfo/flashcoders