+ Reply to Thread
Results 1 to 5 of 5

Which Excel functions work in user-defined functions ?

  1. #1
    Registered User
    Join Date
    04-13-2012
    Location
    Iowa
    MS-Off Ver
    Excel 2003
    Posts
    26

    Which Excel functions work in user-defined functions ?

    Which Excel functions work in user-defined functions ?

    Partly through time-consuming trial and error, and partly through asking questions, I have learned that the built-in DATE() function in Excel doesnít work in a user-defined function. But DATESERIAL() does the same thing and DOES work in a user-defined function but doesnít work when directly entered into an Excel spreadsheet.

    Is there a list anywhere of which built-in functions work and donít work in both Excel and user-defined functions? or am I missing something here?

    Thanks.

  2. #2
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs
    MS-Off Ver
    MS Office 365 Win 11 Home 64 Bit
    Posts
    20,962

    Re: Which Excel functions work in user-defined functions ?

    Look at this site. You might be able to compare the regular functions to the VBA functions and see which ones are the same.

    http://www.techonthenet.com/excel/index.php
    Alan


    Have you debugged your code?
    Database Normalization
    What is Power Query
    Man's Mind Stretched to New Dimensions Never Returns to Its Original Form

  3. #3
    Forum Guru shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,677

    Re: Which Excel functions work in user-defined functions ?

    If you type WorksheetFunction. Intellisense will show the functions available to VBA.
    Entia non sunt multiplicanda sine necessitate

  4. #4
    Registered User
    Join Date
    04-13-2012
    Location
    Iowa
    MS-Off Ver
    Excel 2003
    Posts
    26

    Re: Which Excel functions work in user-defined functions ?

    Sorry, SHG, I don't understand. Where should I type WorksheetFunction? I typed it into the Excel Help box but didn't get anything helpful. and what is Intellisense? First time I have tried to do this sort of thing, so I don't know the basics.

    Thanks again.

  5. #5
    Forum Guru shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,677

    Re: Which Excel functions work in user-defined functions ?

    In a procedure (Sub or Function) in the visual basic editor.

  6. #6
    Registered User
    Join Date
    04-13-2012
    Location
    Iowa
    MS-Off Ver
    Excel 2003
    Posts
    26

    Re: Which Excel functions work in user-defined functions ?

    Thanks, I think I got it. If I type WorksheetFunction in a Sub or Function and then press F2, then I do get a list of VBA functions. Atleast, I think that's what I'm seeing. I also found this webpage: http://www.techonthenet.com/excel/fo...ndex_alpha.php
    which seems to contain an alphabetical list of all functions with (VBA) after the ones that are unique to VBA, so I think that's what I want.
    Thanks !

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Tags for this Thread

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