How to get a Tool Tip for USER DEFINED FUNCTION's in the cell while typing the function

all4excel

Active Member
Joined
Feb 15, 2008
Messages
435
Dear Experts,

I have gradually started learning about UDF's and the first thing which came to my mind was that there should be some mechanism to make it easier for the user to provide the necessary arguments...

I came across a lot of articles on this which gave information on making the information available while using it through Insert Fx...

However, I am in the habit of typing the functions so I would be keen to get the Yellow Tool Tip which helps me to understand what data i need to provide while using the UDF..

HTML:
Vlookup ( lookup_value, table_array, col_index_num, [range lookup] ) 
[COLOR=#6B7770][FONT=Open Sans]I would be happy if my UDF's would be so informative to other users..
</span>[/FONT][/COLOR]
'http://spreadsheetpage.com/index.php/tip/user-defined_function_argument_descriptions_in_excel_2010/
Public Sub DescribeFunction()
Dim FuncName As String
Dim FuncDesc As String
Dim Category As String
Dim ArgDesc(1 To 3) As String


FuncName = "EXTRACTELEMENT"
FuncDesc = "Returns the nth element of a string that uses a separator character"
Category = 7 'Text category
ArgDesc(1) = "String that contains the elements"
ArgDesc(2) = "Element number to return"
ArgDesc(3) = "Single-character element separator"


Application.MacroOptions _
Macro:=FuncName, _
Description:=FuncDesc, _
Category:=Category, _
ArgumentDescriptions:=ArgDesc
End Sub
[/CODE]


The CODE in the FUNCTION is as below

Code:
Function EXTRACTELEMENT(Txt, n, Separator) As String     EXTRACTELEMENT = Split(Application.Trim(Txt), Separator)(n - 1)
End Function


Warm REgards
all4excel
 

Excel Facts

Move date out one month or year
Use =EDATE(A2,1) for one month later. Use EDATE(A2,12) for one year later.

Forum statistics

Threads
1,223,637
Messages
6,173,489
Members
452,515
Latest member
archcalx

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top