ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   User Defined Function Help (https://www.excelbanter.com/excel-worksheet-functions/270813-user-defined-function-help.html)

Michael Dobony

User Defined Function Help
 
I built a user defined Excel 2007 function with 2 mandatory input variables
and 1 optional variable. Is there any way to display which variable I am
adding like the built-in functions do?

Mike D.

Stan Brown

User Defined Function Help
 
On Mon, 23 May 2011 20:23:38 -0500, Michael Dobony wrote:

I built a user defined Excel 2007 function with 2 mandatory input variables
and 1 optional variable. Is there any way to display which variable I am
adding like the built-in functions do?


Maybe it's just me, but what do you mean by "display which variable I
am adding"? Maybe an example of what you're trying to do would help.

--
Stan Brown, Oak Road Systems, Tompkins County, New York, USA
http://OakRoadSystems.com
Shikata ga nai...

Ron Rosenfeld[_2_]

User Defined Function Help
 
On Mon, 23 May 2011 20:23:38 -0500, Michael Dobony wrote:

I built a user defined Excel 2007 function with 2 mandatory input variables
and 1 optional variable. Is there any way to display which variable I am
adding like the built-in functions do?

Mike D.


If you enter the formula using the function wizard, and have named your input variables with meaningful names, you can get some prompting that way.

You could use a method shown he http://www.jkp-ads.com/articles/RegisterUDF00.asp

That article also describes that Excel 2010 now allows you to set the Argument Description easily with VBA code.


Michael Dobony

User Defined Function Help
 
On Mon, 23 May 2011 22:03:26 -0400, Stan Brown wrote:

On Mon, 23 May 2011 20:23:38 -0500, Michael Dobony wrote:

I built a user defined Excel 2007 function with 2 mandatory input variables
and 1 optional variable. Is there any way to display which variable I am
adding like the built-in functions do?


Maybe it's just me, but what do you mean by "display which variable I
am adding"? Maybe an example of what you're trying to do would help.


When you type in a function name and put in the first parentheses there is
a window that opens up below the cell to tell you the inputs that the
function requires. Type "=fv(" in a blank cell and the help window below
shows "FV(rate, nper, pmt, [pv], [type])".

Stan Brown

User Defined Function Help
 
On Mon, 23 May 2011 23:33:06 -0500, Michael Dobony wrote:

On Mon, 23 May 2011 22:03:26 -0400, Stan Brown wrote:

On Mon, 23 May 2011 20:23:38 -0500, Michael Dobony wrote:

I built a user defined Excel 2007 function with 2 mandatory input variables
and 1 optional variable. Is there any way to display which variable I am
adding like the built-in functions do?


Maybe it's just me, but what do you mean by "display which variable I
am adding"? Maybe an example of what you're trying to do would help.


When you type in a function name and put in the first parentheses there is
a window that opens up below the cell to tell you the inputs that the
function requires. Type "=fv(" in a blank cell and the help window below
shows "FV(rate, nper, pmt, [pv], [type])".


Than ks.

You would need to write your function within an .xla or .xlam add-in,
not a regular workbook. You would need to publish your help text
within the add-in. I'm sorry, I know it can be done, but I don't
know how.

--
Stan Brown, Oak Road Systems, Tompkins County, New York, USA
http://OakRoadSystems.com
Shikata ga nai...


All times are GMT +1. The time now is 10:37 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com