Excel XLL (Excel-DNA) Non-Volitile UDF called during undesired Calculate when Excel opens Workbook saved in previous version. RRS feed

  • Question

  • Hello,

    I have an issue where Excel 2016 is running a Calculate when opening up a Workbook saved in Excel 2013. There are thousands of XLL UDF calls in the Workbook and it takes a very long time to open the file. The workbook cannot be saved in Excel 2016. The UDF is written in a C# XLL Add-in that uses Excel-DNA. It is decorated with [ExcelFunction(IsVolatile = false)].

    I have been looking for a way to prevent this re-calculation without using a registry key modification (FullCalcOnLoadOldFile):

    • "
    • "

    I have been looking at returning the original value of the cell if the Workbook is performing an undesired re-calculation. I saw this post on StackOverflow mentioning that it is it possible to return the original value in an XLL by flagging the function as a macro function.

    • "

    I have not been able to find a reference on how to do this. Would someone know how to identify an XLL UDF as a macro function? Is anyone familiar with a way to only return the existing cell value instead of recalculating the value using the UDF?

    Please Advise,


    Monday, November 26, 2018 11:22 PM

All replies