try / catch

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:

Leave a Reply

Your email address will not be published. Required fields are marked *

Proudly powered by WordPress | Theme: Baskerville 2 by Anders Noren.

Up ↑