ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   DLL that takes and returns ranges does not always work (https://www.excelbanter.com/excel-programming/399689-dll-takes-returns-ranges-does-not-always-work.html)

BigBrother

DLL that takes and returns ranges does not always work
 
Hi,

I have a DLL written in C++ that takes ranges as arguments and returns also
a range. For some reason it does not always return numerical values. In
other words, I need to click "Shift+Ctrl+Enter" repeatedly to get it to work.
When it does not return numerical values, it fills in the cells with
"#VALUE!". Any idea on how to fix this?

The DLL has an embedded optimization process that runs longer for certain
input values. Could this be a problem? Do I need to slow Excel down somehow
to make it wait for the DLL to finish the optimization. If so, any idea on
how to do this?

Thanks tons!

PS: Here is my linker line in Excel:
Declare Function baBDTTree Lib "C:\...\BDTdll.dll" (a() As Double, b() As
Double, c() As Double, n As Integer, deltaT As Double) As Double



All times are GMT +1. The time now is 11:01 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com