# A newbie's question about IOErrorEvent

**URL:** https://forum.kirupa.com/t/a-newbies-question-about-ioerrorevent/301154
**Category:** flash
**Created:** [December 4, 2009, 1:47am UTC](https://forum.kirupa.com/t/a-newbies-question-about-ioerrorevent/301154 "2009-12-04T01:47:28Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![OhCaye](https://avatars.discourse-cdn.com/v4/letter/o/47e85d/32.png) [@OhCaye](https://forum.kirupa.com/u/OhCaye)
#### Post date: [December 4, 2009, 1:47am UTC](https://forum.kirupa.com/t/a-newbies-question-about-ioerrorevent/301154/1 "2009-12-04T01:47:28Z")

</div>

Hello, I am new to AS3 and Flash in general, and hate asking dumb questions and would like to find answers on my own, but sometimes don’t know what questions to ask/google.

My situation is that I am designing a mini-website that loads external swfs. One of my swfs is missing, so when I hit the button whose function is to load it, I get an output message that says:

Error #2044: Unhandled IOErrorEvent:. text=Error #2035: URL Not Found.

So far, this makes sense to me. I got curious about how to let the user know that the swf is missing or otherwise let him or her know that I made a mistake, so I’ve learned about IO\_ERROR. I came up with the following code and now I am not getting any error messages - but also nothing is happening. If there is content in the Loader already, it doesn’t go away. If the Loader is empty, it stays empty.

function page4content(evt:MouseEvent):void {  
var myURL:URLRequest=new URLRequest(“page4.swf”);  
myLoader.contentLoaderInfo.addEventListener(IOErrorEvent.IO\_ERROR, ioErrorHandler);  
function ioErrorHandler(e:IOErrorEvent):void {  
var myURL:URLRequest=new URLRequest(“missing\_file.swf”);  
}  
addChild(myLoader);

Can anyone put me on the right track - tell me about a tutorial or tell me the right words to google? Thanks for your patience.
