# Load Movie AS3 doesnt unload current image

**URL:** <https://forum.kirupa.com/t/load-movie-as3-doesnt-unload-current-image/298489>\
**Category:** Uncategorized\
**Created:** [October 20, 2009, 1:17am UTC](https://forum.kirupa.com/t/load-movie-as3-doesnt-unload-current-image/298489 "2009-10-20T01:17:40Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![DeltaFrog](https://avatars.discourse-cdn.com/v4/letter/d/b2d939/32.png) [@DeltaFrog](https://forum.kirupa.com/u/DeltaFrog)\
**Post date:** [October 20, 2009, 1:17am UTC](https://forum.kirupa.com/t/load-movie-as3-doesnt-unload-current-image/298489/1 "2009-10-20T01:17:40Z")

</div>

The code works but with an issue. When I load an image it replaces the current one loaded but when I alpha tween the image to zero I see both images fading out on top of each other like the first one is still loaded but underneath the current one. Any body run into this before? :hang:

var imageLoader:Loader;  
function loadImage(url:String):void {  
// Set properties on my Loader object  
imageLoader = new Loader();  
imageLoader.load(new URLRequest(url));  
imageLoader.contentLoaderInfo.addEventListener(ProgressEvent.PROGRESS, imageLoading);  
imageLoader.contentLoaderInfo.addEventListener(Event.COMPLETE, imageLoaded);  
}  
//loadImage(“largeImages/k1.jpg”);

function imageLoaded(e:Event):void {  
// Load Image

}

function imageLoading(e:ProgressEvent):void {  
//trace(“loading”);

}

loadImage(“typical.jpg”);
