ExitOnError -- enable/disable Hollywood's error handler
This function enables or disables Hollywood's error handler. If the error handler is enabled and an error occurs, your script will either be stopped and Hollywood will display the error message, or, in case you have installed a custom error handling callback using RaiseOnError(), this custom error handling callback will be executed. See Error handling for details.

It can be useful to disable the error handler for a very short time if you need to check whether a certain command has succeeded or not. This can be done by enclosing the command in an ExitOnError() block. See Error handling for details. It is not advised to disable the error handler for a longer time because errors can easily accumulate so in general you should only keep the error handler enabled.

In Hollywood 7.1 and up the new question mark syntax to check for errors is preferable to using ExitOnError() because it is much shorter and less prone to accidental mistakes. See Error handling for details.

True to enable the error handler; False to disable it

Show TOC