- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
I'm using Visual Studio 2019.
I have a Vb project that is calling a dll in fortran that i wrote.
The fortran code is using the library LINK_FNL_SHARED.H.
When i ran the vb project that is calling the dll,i received an error:"system.dllnotfoundexception".
Both the vb project and fortran project are in debug mode x64.
-But when i try to mark in comment the line code: CALL RNSET(ISEED),CALL RNUN(NR,R)
all is fine and the dll is recognized and the code is running!
I have added the path of the library ,the dll and the linker also.
I have tested and tried to create a project only in fortran using this library with no vb and the code is succesfull !
What am i missing in my vb project so that it can call the fortran dll using a call to LINK_FNL_SHARED.H lib?
Please see the attached files of my code .
Thank you
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Your code uses routines from the IMSL library. If, when your VB program is run, the IMSL DLLs are not accessible through the PATH environment variable, the program will abort.
If RNSET and RNUN are the only IMSL routines that are needed, you could use the Fortran intrinsics RANDOM_SEED and RANDOM_NUMBER instead, and remove the dependency of your VB project on IMSL.
Please do not confuse yourself and readers by calling LINK_FNL_SHARED.H as a "library". That include file, which is all of 40 bytes in length, simply adds an OBJCOMMENT directive for the linker to use. The library itself is called imslmkl_dll.lib .
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi thank you,
But RNSET and RNUN are the NOT only the IMSL routines that i need!
how can i make my project run?
Thank you
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I had also tried to add directly to the vb and fortan project the imslmkl_dll.lib but still the same error
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Which other IMSL routines do you use? I have to note that your screenshots contain little useful information that I can use.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Adding a .lib to a VB project will not do anything useful.
VB will say "DLL not found" when a dependent DLL isn't found. If you have purchased IMSL, you'll need to make sure that its DLLs are in a folder included in the PATH system environment variable. You can contact Rogue Wave for support on IMSL.

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