I was delighted to (eventually) be able to access a FORTRAN 6.1 DLL from MS
Excel. The example DLL I made and used had only discrete numerical inputs
and these were supplied by simply selecting the appropriate spreadsheet
cells after typing the function name, adding the commas, etc. So far, so
My next attempt involved arguments that consisted of arrays of numbers. The
problem comes with the need to supply FORTRAN only the first element of an
array (or, the address?). How can I supply only the first element when
selecting a range of cells in the spreadsheet? Also, what is the correct way
to declare a function in VBA so that it recognizes that a particular
argument is an array?
The FORTRAN function looks like :
and my VBA declaration :
Declare Function LINEARLOOKUP Lib "LibName.DLL" Alias "_LINEARLOOKUP*16"
(Byval X as Single,ByVal XARRAY() as single,byVal YARRAY() as
single,NUMENTRIES as long) as single
The result, when attempting to supply the array arguments as a selection of
cells is #VALUE! I'm stumped and terribly frustrated. Please help if you
(2) I am u user in the JSF program at Boeing and as such I do not have
access to the installation disks; is there some way I can become a recipient
of the VF Newsletter?
Thanks in anticipation