Add Description Text to a UDF in Excel

Add to Favorites

How to add a description for a UDF (User Defined Function). This allows the user to understand what the function does.

Note that this description text is only visible when you open the Function Arguments window by clicking the Insert Function (fx) button.

Steps to Add a Description to a UDF

  1. Go to the VBA Editor window (Alt + F11) and make sure you have input the UDF.
  2. Hit F2 to open the Object Browser window.
  3. Select VBA Project from the top drop-down menu in the window.
  4. Look to the pane on the right of the window and you should now see your UDF:

    If you do not see the UDF in the right pane, click through the items in the left pane until it appears.
  5. Right-click your UDF and then click Properties
     
  6. In the window that opens, type the description that you want in the Description box and then hit OK.
  7. Close the Object Browser window, save the file, and go back to Excel. When you type the function and click the fx (insert function) button, you will new see the description of the function that you just entered.

    This window also shows any arguments that the function takes.

Notes

It requires a lot of effort to get a UDF to function more like a regular Excel function, but this is one of the easiest things that you can do to give the user more information about what the function does and how to use it.

Make sure to download the sample file attached to this tutorial to work with this example in Excel.


Downloadable Files: Excel File

Similar Content on TeachExcel
How to Add Boxes, Buttons, Arrows, Speech-Bubbles, Hearts, and More to a Spreadsheet in Excel
Tutorial: In this tutorial I am going to cover inserting and editing Shapes in an Excel workbook, as...
Add Image Background to a Chart in Excel
Tutorial: How to use an image for the background of a chart in Excel. Simple but fun way to spruce...
Add a Drop Down Menu to a Cell in Excel - Data Validation Macro
Macro: Add a drop down menu or list to a cell in Excel with this free Excel macro. This is a...
Get Comment Text from Cell Comments in Excel - UDF
Macro: This free Excel UDF outputs all text from a comment in Excel. This benefit of this UDF is ...
Reverse the Contents of a Cell in Excel - UDF
Macro: Reverse cell contents with this free Excel UDF (user defined function). This will mir...
Update, Change, and Manage the Data Used in a Chart in Excel
Tutorial: In this tutorial I am going to show you how to update, change and manage the data used by ...