Skip to main content

try - catch - finally

An example FPL code block showing try / catch / finally logic support:

function main() {
try {
nonExistentFunction();
} catch (e) {
printf("%s: %s", e.name, e.message);
// print out: ReferenceError: nonExistentFunction is not defined
} finally {
// execute after the try block and catch block(s) execute,
// but before the statements following the try...catch...finally block
}
}