Package com.exceljava.jinx
Interface ErrorHandler
public interface ErrorHandler
ErrorHandler interface for handling errors thrown when calling Excel functoins, macros, menus and ribbon actions.
A custom error handler can be configured in the jinx.ini file, for example:
[JINX]
error_handler = com.mycompany.myapp.ErrorHandler
- Since:
- 2.0
-
Method Summary
Modifier and TypeMethodDescriptionvoidactionError(String actionName, Method method, Throwable error) Called when an exception is thrown calling an action.functionError(String functionName, Method method, Throwable error) Called when an exception is thrown when calling a worksheet function or UDF.macroError(String macroName, Method method, Throwable error) Called when an exception is thrown when calling a macro.voidCalled when an exception is thrown calling a menu function.
-
Method Details
-
functionError
Called when an exception is thrown when calling a worksheet function or UDF.- Parameters:
functionName- Excel name of the function called.method- Java method mapped to the function.error- Exception thrown.- Returns:
- Object to be returned to Excel. If null, an Excel error code will be used.
-
macroError
Called when an exception is thrown when calling a macro.- Parameters:
macroName- Excel name of the macro called.method- Java method mapped to the function.error- Exception thrown.- Returns:
- Object to be returned to Excel. If null, an Excel error code will be used.
-
actionError
Called when an exception is thrown calling an action.- Parameters:
actionName- Name of the action called.method- Java method mapped to the menu item.error- Exception thrown.
-