- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I'm trying to call bak from Fortran (Visual Fortran) to Visual Basic (VB). Before I added the callback code, my Fortran code compiled and linked without a problem. I list the modifications I have introduced below. But here is the error message I get in the linking process:
" Linking...
LINK : fatal error LNK1181: cannot open input file "imsl.lib"
Error executing link.exe.
Memfor.dll - 1 error(s), 1 warning(s)"
If I remove "imsl.lib" from Project/Settings.../Link/Object/library module, I still get an error message - now over some other object.
Here is the basis for how I am trying to achieve callback.
In VB:
* I have defined a "callback"er function in a global module of VB.
* My call to Fortran has been expanded with one additional argument:
call Fortranroutine(T, AddressOf callback)
In Fortran:
* I have added 4 bytes in the number of argument bytes of the *.def file.
* The Fortranroutine code looks as follows:
Question:
--Does anyone see a problem with the way I have tried to organize the callback?
-- Does anyone see what is the problem with the linking process?
Thanks!
-Bernt Lie
" Linking...
LINK : fatal error LNK1181: cannot open input file "imsl.lib"
Error executing link.exe.
Memfor.dll - 1 error(s), 1 warning(s)"
If I remove "imsl.lib" from Project/Settings.../Link/Object/library module, I still get an error message - now over some other object.
Here is the basis for how I am trying to achieve callback.
In VB:
* I have defined a "callback"er function in a global module of VB.
* My call to Fortran has been expanded with one additional argument:
call Fortranroutine(T, AddressOf callback)
In Fortran:
* I have added 4 bytes in the number of argument bytes of the *.def file.
* The Fortranroutine code looks as follows:
subroutine Fortranroutine(T, VBcallback) real T integer i integer, external :: VBcallback i = VBcallback(T) ....
Question:
--Does anyone see a problem with the way I have tried to organize the callback?
-- Does anyone see what is the problem with the linking process?
Thanks!
-Bernt Lie
Link Copied
1 Reply
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The error message from the link has nothing to do with the way you construct your callback. It simply can'tfind the library. Make sure that the path to ..DF98IMSLLIB is in the list under Tools..Options..Directories..Library Files
Steve
Steve
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