Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Documenting VBA code for Excel Auto Complete

Tags:

excel

vba

When writing a custom function to use in excel using VBA, How to write the documentation comments so that the excel automatically displays during auto-fill of a formula?

For example, when we start typing VLookUp, It shows what Vlookup does as a tool tip, shows the input variable names and if we press Insert Function from the ribbon, a dialog is shown with clear explanation of the function... How can we achieve that while writing custom functions in VBA?

like image 763
Ashok Avatar asked Mar 12 '11 11:03

Ashok


People also ask

How do you AutoComplete in Excel VBA?

The first keyboard shortcut is Ctrl + Space . It shows the Intellisense menu so that you can autocomplete words that you've already started to type. The second shortcut is Ctrl + J . It brings up the menu when it has disappeared and you want to view it again.

How do you AutoComplete in Excel?

On the Excel menu, click Preferences. Under Formulas and Lists, click AutoComplete. In the Show the menu only after I've typed box, enter the number of letters that you want to type before the AutoComplete menu appears. Tip: You can also show the AutoComplete menu by pressing CONTROL + OPTION + DOWN ARROW .


1 Answers

I believe you must use Application.MacroOptions to register your function and its description, and optionally provide a help file to make the Help on this Function link work.

Not sure how to provide inline description for the parameters though.

like image 133
GSerg Avatar answered Oct 01 '22 07:10

GSerg