# Upload and memory usage in flash

**URL:** <https://forum.kirupa.com/t/upload-and-memory-usage-in-flash/299292>\
**Category:** Uncategorized\
**Created:** [November 2, 2009, 10:19pm UTC](https://forum.kirupa.com/t/upload-and-memory-usage-in-flash/299292 "2009-11-02T22:19:06Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![kharddie](https://avatars.discourse-cdn.com/v4/letter/k/d9b06d/32.png) [@kharddie](https://forum.kirupa.com/u/kharddie)\
**Post date:** [November 2, 2009, 10:19pm UTC](https://forum.kirupa.com/t/upload-and-memory-usage-in-flash/299292/1 "2009-11-02T22:19:06Z")

</div>

![](http://forum.kirupa.com/uploads/kirupa/5913/185baef3cbd1ba6a.gif) **upload and memory usage in flash**  
I have a movie that am loading external 27 movie clips. after a while the flash projector crushes. when i look at the the task manager flash Mem usage is 171000k.

the more i upload the more the memory keeps increasing.  
i thought when u upload a movie clips in flash they keep replacing the one before and so the memory does not keep increasing?

what am i doing wrong???

–kharddie

[COLOR=black][COLOR=black]var loaderScenario:Loader;  
loaderScenario =new Loader();  
loaderScenario.contentLoaderInfo.addEventListener( IOErrorEvent.IO\_ERROR,loadingError);  
loaderScenario.contentLoaderInfo.addEventListener( ProgressEvent.PROGRESS,updateInfo);  
loaderScenario.contentLoaderInfo.addEventListener( Event.COMPLETE,doneLoad);

var tempSwfHolder:MovieClip = new MovieClip();  
MovieClip(Globals.data.root0).scenariosHolder.addC hild(tempSwfHolder);// Add empty MC initially so the nextClip function can be generic

function doneLoad(e:Event):void {

MovieClip(Globals.data.root0).scenariosHolder.remo veChild(tempSwfHolder);  
tempSwfHolder=MovieClip(loaderScenario.content);  
loaderScenario.unload();  
MovieClip(Globals.data.root0).scenariosHolder.addC hild(tempSwfHolder);  
}  
[/COLOR][/COLOR]
