TonyD
Joined: 15 Apr 2009 Posts: 1
|
Posted: Thu Apr 16, 2009 10:05 am Post subject: dll communication |
|
|
Hello,
I'm trying to run fortran dlls from visual basic. I can compile the dlls and call them from the main visual basic code fine, the problem is I need the dlls to be able to call subroutines from other dlls. All the dlls are fortran and compiled with FTN95. For example, the following will work fine since both the subroutines are in the same file and compiled to the same dll:
Code: |
F_stdcall SUBROUTINE SOLVE()
print * , 'Now in solve'
call result()
END Subroutine
Subroutine result()
print *, ' This is the result'
end subroutine
|
If I need to call result from another dll though:
Code: |
F_stdcall SUBROUTINE SOLVE()
print * , 'Now in solve'
call result()
END Subroutine
F_stdcall Subroutine result
print *, ' This is the result'
end subroutine
|
- now two separate dlls
The program just hangs when it tries to call result. I imagine I need to write an interface between the two dlls but even if this is correct I don't know how to do it.
I would be grateful for any help on this as I really need it to work.
Thanks,
Tony |
|