ad_try (public)
ad_try [ -auto_abort ] body [ args... ]
Defined in packages/acs-tcl/tcl/exception-procs.tcl
Generic code for OpenACS to handle exceptions and traps based on Tcl's primitives. This implementation is a slight generalization of the Tcl 8.6 built-in ::try, which handles ad_script_aborts automatically. The command "ad_try" should replace the various exception handling constructs such as "catch", which tend to swallow often error conditions, making debugging unnecessarily hard. It will make "with_finally" and "with_catch" obsolete, which should be marked as deprecated in the not-to-far future.
- Switches:
- -auto_abort (optional, boolean, defaults to
"true"
)- Parameters:
- body (required)
- See Also:
- with_finally
- with_catch
- Partial Call Graph (max 5 caller/called nodes):
- Testcases:
- create_form_with_form_instance