Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.

Type Library out of Fortran-DLL

fobermaier
Beginner
533 Views
Hello,

I'm currently working on an VB-ActiveX-Control that has to use some routines out of a previosly developed Fortran-DLL. These were made accessible with 'Declare' statements.

Unfortunately the VB-IDE crashes while debugging the bundle, just like mentioned in MSDN-KnowledgeBase article Q241896 - 'PRB: Threading Issues with Visual Basic 6.0 ActiveX Components'.

Microsoft suggests to use Type Libraries instead of the Declare-Statement (Q189133 HOWTO: Make C DLL More Accessible to VB with a Type Library).

Now I need some advice how to declare
- fixed and variable length character strings
- integer/real arrays with variable size

I'm using VB6 with SP5 and DVF6.6B.

Thanks
Felix Obermaier
0 Kudos
1 Reply
gfthomas8
Novice
533 Views
If you have the source to the CVF DLL, rebuild the DLL as a COM in process server, ie, AX DLL. This has a built in TBL so you make a reference to it in your VB6 project and get rid of all the Declares. Look at the CVF AX DLL in VB6's object browser.

If you don't have the source, the CVF is likely a straight DLL with exports. Do the bugging in VS97: designate your VB6 .exe as client and away you go.

HTH,
Gerry T.

PS If you have documentation on the CVF DLL you can perhaps write a .tbl for it even though it's not an AX DLL. This involves doing some IL but I don't see the advantage: all you get is to omit Declares and the option to debug in the VB IDE. You can also distribute the non AX DLL to other VB users provided you provide them with the .tbl.
0 Kudos
Reply