In Excel 2007, how do I add a description and parameter hints to a user-defined function? When I start typing a function invocation for a built-in function, Excel shows a description and parameter list--a tooltip. I'd like to do the same for the functions I define.
Not just for the formula insert wizard, but in the formula box, so if I key "=myFun("
, at the "("
the tooltip pops up just like it does for "=average("
There's no help in VBA Help, none on MSDN and none on any of the Excel and VBA dedicated forums I can find, so this is clearly a long shot.
Place a hyperlink with a screen tip underneath the combobox, when you mouse over the combobox the screen tip will pop up. You can place the hyperlink on many cells if you intend on stretching the combobox over many cells.
I usually provide instructions to my users to type =myfunction("help") to get the syntax help and just put an if statement to return the intellisense.
Not a tooltip solution but an adequate workaround:
Start typing the UDF =MyUDF(
then press CTRL + Shift + A and your function parameters will be displayed. So long as those parameters have meaningful names you at-least have a viable prompt
For example, this:
=MyUDF(
+ CTRL + Shift + A
Turns into this:
=MyUDF(sPath, sFileName)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With