Wrapping a XLL as if it were a DLL
Literally only seconds after posting I realized that I had typed in
the path with ".dll" instead of ".xll". Changing the extension made
THAT part work at least. Now I'm getting this:
Error 49, Bad DLL calling convention.
I sort of expected I would get something like this, but just to be
sure, does this mean I have written down the Private Declare Function
parameter list incorrectly? Assuming this is the case...
The XLL in question is passed a series of inputs that are represented
as ranges on a sheet. We have adapted this to use 2D arrays of Double
instead, which seems to pass into Application.Run just fine. But
here's where I'm lost: should I declare the inputs like...
...., dates() as Double, conventions() as Double, ...
or
...., dates as Any, conventions as Any, ...
or even
...., dates as Variant, conventions as Variant, ...
or maybe...
...., dates() as Variant, conventions() as Variant, ...
I *sort of* understand the differences between these (well, not sure
about the last two) but I can't say I *really* understand the nuances.
Is something:
Dim dates() as Double
passed into calls as a Variant? Or Variant()? Or is there a difference
in calling conventions between these?
Thanks!
Maury
|