- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I'm using CVF and Visual Studio .NET.
I included the Fortran dll in the C++ project, and the compiler and linker do not give any errors.
However when I try to use the C++ dll in Stata, I get an error message saying that the fortran dll was not found.
any clues on what the problem is?
Link Copied
2 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
1- If your C++ application is on another computer where CVF is not installed, then you would need some CVF run-time libraries installed on this computer. Download VBFRUN66BI.exe from hereand install it on the computer without CVF.
2- If C++ application is on the same computer as CVF, then check the name, spelling, and argument list of both your CVF DLL and call statement in C++.
3- Check even decorations for exporting your DLL name in CVF. Search for "calling conventions" or "calling fortran from C" in this forum.
Sabalan.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
CVF 6.5, Visual Studio .NET 2003, and Stata 8.2 are all on the same computer.
In C the code is
Code:
extern __declspec(dllimport) void __stdcall fcstata(int *n);
In Fortran
Code:
There are no compile or link errors.subroutine fcstata(n) !dec$ attributes dllexport, alias:'_fcstata@4'::fcstata
I included the fortran.lib file in the VC project.
I've even triedsaving the fortran .dll in the VC debug directory.
I have no clue what the problem is.

Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page