I have in my Fortran code:
dll_handle = LoadLibrary('Test123.dll'//char(0))
However this Fortran code may also be called from a C++ wrapper which may have already dynamically loaded this DLL. From a quick test the Fortran call does not simply return the handle that the C++ wrapper got when it loaded it, but returns a different handle. Has the DLL been loaded twice? If so is this a problem?