Exception / Error Handlers Options

Top  Previous  Next

 VS   VB6   VB5   VBA 

The Exception / Error Handlers Options section of the Team Options tab allows you to customize the templates of the Insert Exception / Error Handler feature:

ExceptionHandlers

To create an exception / error handler you use the following window:

ExceptionHandler

In this window you enter the following properties:

  • Description: a text describing the exception / error handler.
     
  • Template Text: the actual text of the exception / error handler. Using the Insert > button, you can include in the text predefined variables (whose value is assigned automatically by MZ-Tools, such as selected text, name of method, etc.) or user-defined variables (whose value is asked when the exception / error handler is inserted).
     
  • Author: the author of the exception / error handler.

For Visual Studio:

  • Expansion Keyword (optional): a keyword that you can type in the code and then "expand" it to the whole template text. This can save you time since you avoid the window to select an exception handler when you use the Insert Exception Handler toolbar button or menu. To expand a keyword to replace it by the actual associated exception handler template text you invoke the MZTools8.ExpandKeyword command provided by MZ-Tools (typically through a keyboard shortcut).
     
  • Command Name (optional): MZ-Tools provides nine commands (MZTools8.ExceptionHandler1 ... MZTools8.ExceptionHandler9) that you can associate with exception handler templates. When you execute an exception handler command (typically through a keyboard shortcut, or creating a button on a toolbar from that command), the associated code template text is inserted in the code.

For VB6 / VB5 / VBA:

  • Expansion Keyword (optional): a keyword that you can type in the code and then "expand" it to the whole template text. This can save you time since you avoid the window to select an error handler when you use the Insert Error Handler toolbar button or menu. To expand a keyword to replace it by the actual associated error handler template text you use the keyboard shortcut that you associate with the Expand Keyword feature in the Keyboard Shortcuts Options:

ExpandKeywordKeyboardShortcut
 

  • Keyboard Shortcut (optional): you can define a keyboard shortcut that, when invoked, the associated error handler template text is inserted in the code.

See Also:

Insert Exception / Error Handler

Predefined Variables

User-defined Variables