#1
|
|||
|
|||
#REF Error when calling VBA Function
#REF Error
I retrieved a VBA function (for astronomy) from the web that calculates the Julian day number for a specified date. If I call this function from a spreadsheet it is recognised by Excel (the Insert Function also sees it) but returns a #Ref error for any entry. I created a Test sub() and called the function, thus allowing me to step through it and display the result in a message box. It correctly evaluated, and displayed, the function result for my input. The function contains no cell references; it justs performs straightforward arithmetical calculations based on six input parameters. Can anyone please suggest, what the problem may be? I am using Excel 2016 on Windows 10. Many thanks. |
#2
|
|||
|
|||
Any chance of you posting a sample workbook containing the sub and UDF so we know, and/or can see, what actually takes place ?
|
Tags |
#ref, udf, vba |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
#REF! Error in calling VBA function disappears when function is copied | lcaretto | Excel Programming | 2 | 05-26-2014 07:19 PM |
Sub or Function not defined error - GetParaIndex Word 2010 | jec1 | Word VBA | 1 | 05-24-2012 11:58 PM |
Compile error: sub or function not defined.. | xena2305 | Excel Programming | 0 | 08-02-2011 10:17 AM |
Re-Calling Sent Email | freschij | Outlook | 1 | 12-06-2010 09:16 PM |
calling images with a button | sammer021486 | PowerPoint | 0 | 01-13-2010 08:24 AM |