Microsoft Office Tutorials and References
In Depth Information
Dealing with the Insert Function Dialog Box
Table 10-1: Function Categories
Category Number
Category Name
12
Macro Control
13
DDE/External
14
User Defined
15
Engineering
16
Cube
17
Compatibility*
*The Compatibility category is new to Excel 2010.
You can also create custom function categories. Instead of using a number for the Category
argument for MacroOptions , use a text string. The statement that follows creates a new
function category named VBA Functions, and assigns the Commission function to this category:
Application.MacroOptions Macro:=”Commission”, Category:=”VBA Functions”
Adding a function description manually
As an alternative to using the MacroOptions method to provide a function description, you can
use the Macro dialog box.
If you don’t provide a description for your custom function, the Insert Function dialog
box displays the following text: No help available.
Follow these steps to provide a description for a custom function:
1.
Create your function in the VBE.
2.
Activate Excel, making sure that the workbook that contains the function is the active
workbook.
3.
Choose Developer Code Macros (or press Alt+F8).
The Macro dialog box lists available procedures, but your functions won’t be in the list.
4.
Type the name of your function in the Macro Name box.
5.
Click the Options button to display the Macro Options dialog box.
6.
Enter the function description in the Description box (see Figure 10-12).
The Shortcut Key field is irrelevant for functions.
 
Search JabSto ::




Custom Search