+ Reply to Thread
Results 1 to 7 of 7

UDF doesn't appear in Insert Function list

  1. #1
    Registered User
    Join Date
    09-08-2006
    Posts
    5

    UDF doesn't appear in Insert Function list

    I created two functions. One I can access with no problem from the drop-down menu. The other I can't. The function's name is SimonCost, but what appears on the list are two names: SimonCost.SimonCost and module1simon...

    Looking at the functions, they appear identical from a format standpoint. I can't figure out why one is usable and the other isn't. This isn't a formula-related issue.

    Help!

  2. #2
    Forum Moderator davesexcel's Avatar
    Join Date
    02-19-2006
    Location
    Regina
    MS-Off Ver
    MS 365
    Posts
    13,482
    can you show the code?

  3. #3
    Registered User
    Join Date
    09-08-2006
    Posts
    5
    Function SimonCost(Hours As Double)

    SimonCost = 6.74 + (0.48 * Hours) + (1.03 * Hours) + (2.89 * Hours)

    End Function

  4. #4
    Forum Moderator davesexcel's Avatar
    Join Date
    02-19-2006
    Location
    Regina
    MS-Off Ver
    MS 365
    Posts
    13,482
    Could you have SimonCost UDF in two different modules?

  5. #5
    Registered User
    Join Date
    09-08-2006
    Posts
    5
    Nope. I'm thinking that the reason the function doesn't work is because it's not being automatically saved correctly (hence its absence in the function list) because it's such a simple calculation. I could just stick it in the cell and be done with it, but... I'm perplexed

  6. #6
    Forum Moderator davesexcel's Avatar
    Join Date
    02-19-2006
    Location
    Regina
    MS-Off Ver
    MS 365
    Posts
    13,482
    if there are two of them then delete one, it won't work if there are two of them

  7. #7
    Registered User
    Join Date
    09-08-2006
    Posts
    5
    Dave,

    I figured out my problem, but not how to fix it. And cos I'm a total forum newbie, I retitled my issue instead of just posting a reply to this thread. My bad. Anyway, I've distilled it to this: when I create a local function I can't use it as such. The function is being saved with the workbook title as a prefix and I don't understand why.

    Thanks for your patience.

+ 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