+ Reply to Thread
Results 1 to 4 of 4

Show input names in my own VBA-functions

  1. #1
    Registered User
    Join Date
    02-01-2010
    Location
    Denmark
    MS-Off Ver
    Excel 2003
    Posts
    3

    Show input names in my own VBA-functions

    Hello

    I am a beginner with VBA. My question is fairly simple: When I create new functions with VBA, can I have them show the input names when I call them in Excel? For instance if I use the default if-function, it will state that the first input should be the logical test, the next should be the value if true etc. I would like that to be the case as well for my own functions.

    Best regards,
    T

  2. #2
    Valued Forum Contributor
    Join Date
    03-29-2013
    Location
    United Kingdom
    MS-Off Ver
    Office/Excel 2013
    Posts
    1,749

    Re: Show input names in my own VBA-functions

    if you declare it as a public function then yes...
    Elegant Simplicity............. Not Always

  3. #3
    Forum Guru HaHoBe's Avatar
    Join Date
    02-19-2005
    Location
    Hamburg, Germany
    MS-Off Ver
    work: 2016 on Win10 (notebook), private: 365 on Win11 (desktop), 2019 on Win11 (notebook)
    Posts
    8,198

    Re: Show input names in my own VBA-functions

    Hi, Tenshu,

    maybe have a look at Register UDFs.

    Ciao,
    Holger
    Use Code-Tags for showing your code: [code] Your Code here [/code]
    Please mark your question Solved if there has been offered a solution that works fine for you

  4. #4
    Registered User
    Join Date
    05-19-2011
    Location
    San Diego, CA
    MS-Off Ver
    Excel 2010
    Posts
    33

    Re: Show input names in my own VBA-functions

    To clarify, you can use VBA to register the UDF's arguments to be displayed when using the Insert Function dialog from the Ribbon, as shown in the link provided by Holger.

    As far as I know, there is no way to have the arguments appear in the Formula Box (labeled fx) the same way they do for built-in functions like IF() in your example. At least not as of xl2010.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1