The errant cell seems to be C15 on the May sheet which displays the correct result from the function, No circular reference arrows are displayed. I have attached the Workbook with additional sheets.
To reproduce the circular reference in the new workbook do the following:
1) From the May sheet select the cell containing the function and place the curser in the formula bar.
2) Invoke the function by pressing return. This will calculate the date for May correctly using the hard value in Apr!C13 as a seed.
3) Move to the Jun sheet and do the same. In this case we are looking at the result of the UDF in May!C15 rather than a hard value. This should result in the circular reference error message being displayed.
4) Clearing the message leaves a zero (0) value displayed in the cell containing the UDF.
5) Inspecting the Error Checking drop down > Circular references from the Formulas ribbon shows the cell reference May!$C$15 as the one containing the circular reference.
It would seem that we need the value displayed in the cell rather than the contents, a bit like copying a cell containing, say =1+2+3 then using Paste Special>Paste Values123 to get the cell to display 6. I am not sure how to do this in VBA, or indeed if it can be done.
Bookmarks