Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default User Defined Function (UDF) Tooltip

Hi, does anyone know if it is possible create custom tooltips for user
defined functions. I am an Engineer developing an Addin with a few common
functions. A simple example of a user defined function would be:

Public Function CircleArea(Diameter as Double) As Double

CircleArea = 3.1414925 * (Diameter ^ 2) / 4

End Function

When Someone types "=CircleArea(" in Excel I want a tooltip to appear and I
am going to use it to help the user know what the units should be, e.g. in
this case meters [m]. It's not really practical to rely on the arguments
when viewed in the function wizard, if it's used!

Many thanks in advance...
Chris Shorrock
Worcester, England.



  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,298
Default User Defined Function (UDF) Tooltip

when in the IDE, open the Object Browser ( F2) select the VBA Project from
the object dropdown and you will see the function listed under members. If
not, select the correct class until you see the function appear in Members.
Right cklick the function, select Properties and edit the Description. This
will appear in the sheet in one uses the formula button.

There probably to add a tool tip - but I've not come accross it outside of
using C++



"Chris Shorrock" wrote:

Hi, does anyone know if it is possible create custom tooltips for user
defined functions. I am an Engineer developing an Addin with a few common
functions. A simple example of a user defined function would be:

Public Function CircleArea(Diameter as Double) As Double

CircleArea = 3.1414925 * (Diameter ^ 2) / 4

End Function

When Someone types "=CircleArea(" in Excel I want a tooltip to appear and I
am going to use it to help the user know what the units should be, e.g. in
this case meters [m]. It's not really practical to rely on the arguments
when viewed in the function wizard, if it's used!

Many thanks in advance...
Chris Shorrock
Worcester, England.




  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default User Defined Function (UDF) Tooltip

Patrick,
May thanks you for your reply.
The description you suggest is visible when the user accesses the function
via the function wizard. I already have this.
For familiar functions the user usually types it in without the aid of the
wizard. For example:
=SUM(B1:B20) I would normally type in.
For Excel functions as soon as the first of the parentheses is entered, i.e.
"=SUM(" a yellow-background with a description of the argument(s) required
to be passed to the function appears in bold. As you shift through the
arguments the bold focus moves accordingly. This is the functionality that
I'd like to add to my UDFs.
You mention it may be possible to tackle this in C++. I'm not too familiar
with this language but have some Java experience. I'd be interested to hear
your ideas.
Do you know where are the functions such as =SUM() located? I'd like to look
at the code. I've looked at the AddIn modules such as LOOKUP.XLA but they do
not have the tooltip functionality either.
Many Thanks
Chris


"Patrick Molloy" wrote in message
...
when in the IDE, open the Object Browser ( F2) select the VBA Project from
the object dropdown and you will see the function listed under members. If
not, select the correct class until you see the function appear in
Members.
Right cklick the function, select Properties and edit the Description.
This
will appear in the sheet in one uses the formula button.

There probably to add a tool tip - but I've not come accross it outside of
using C++



"Chris Shorrock" wrote:

Hi, does anyone know if it is possible create custom tooltips for user
defined functions. I am an Engineer developing an Addin with a few common
functions. A simple example of a user defined function would be:

Public Function CircleArea(Diameter as Double) As Double

CircleArea = 3.1414925 * (Diameter ^ 2) / 4

End Function

When Someone types "=CircleArea(" in Excel I want a tooltip to appear and
I
am going to use it to help the user know what the units should be, e.g.
in
this case meters [m]. It's not really practical to rely on the arguments
when viewed in the function wizard, if it's used!

Many thanks in advance...
Chris Shorrock
Worcester, England.






Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Display ToolTip for User Defined Function ryguy7272 Excel Discussion (Misc queries) 0 April 22nd 09 07:16 PM
user defined function ub Excel Worksheet Functions 6 April 4th 07 09:42 PM
User Defined Function Samad Excel Discussion (Misc queries) 14 November 16th 05 12:32 PM
User-defined data type; Error: Only User-defined types... tiger_PRM Excel Programming 1 July 18th 04 03:32 PM
User-Defined Function pre-empting Built-in Function? How to undo???? MarWun Excel Programming 1 August 6th 03 09:31 PM


All times are GMT +1. The time now is 06:37 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"