Riverview Church

TRY CATCH

try...catch executes code that may throw an exception, and when the exception is caught, more code may be executed.

SYNTAX

try {
  code
} catch (exception) {
  code
}

EXAMPLES

STRING

VALUE

INTERNAL

else

else if

if

switch

EXTERNAL

Mozilla Developer Network