Try and catch is most handy for handling files with AIR etc. Pretty straightforward, but just incase you forget the syntax:
try { // statements } catch (error:ArgumentError) { trace('An argument error has occured'); } catch (error:Error) { trace('An error has occured which is not argument related'); }
src: (ty)
http://www.foundation-flash.com/tutorials/tryandcatch/
Tech Reference: AS3
Leave a Reply