After the loss of a little hair, the reading of bits of Michael B. Feldman's Software Construction and Data Structures with Ada 95, and with help from Martin Krischik and Simon Wright, I came up with the following.
The code was worked out in the context of the afore-posted
apiproject. If you want to play with this, just take the earlier work and stuff this into it.
First up, the additions to api.ads:
Next, the additions to api.adb:
Next, some VB code to demonstrate ...
... and a sample output.
I'm in the process now of working out how to access the LongLong and DoubleDouble Types. Shall keep you posted.
By the way, the return value will eventually be a pointer as well. That'll keep the VB programmer on his toes.
© Copyright Bruce M. Axtens, 2007