Hallo all We trey to make a fortran.dll and called from VB-6 Since we are not a very experienced fortran-programmer,i need some help This example program as test program for a bigger array routine with two arguments ,but i callecd a runtime Error all ready Error'453' Can't find dll entry point on subarray on C:\john........\subarray2.dll I think that the problem are the lenght of the array and how to pass it to the fortran.dll ,it's make no difference of we pass this lenghts also as a argument to the fortran.dll We do some think wrong .
The vb-6 code are Private sub Command1_click() Dim X( 1 to 10 ) as integer Dim N as Integer Dim R as Integer N = 10 For I =1 to 10 X(I) =I next I Call Subarray2 (X(1) , R ) text1.text = str$ (R) end sub On a module Declare sub SUBARRAY lib'C:\jan.......subarray2.dll\X as Integer,R as Integer
On Fortran FTN95 with the F_ STDCALL as extra compiler options Subroutine SUBARRAY(Arr,R) Integer(kind=3):: Arr(:) Integer(kind=3)::R Integer(kind=3)::J R=0.0 j=10 Do j= I R=R+ Arr( J ) End do End subroutine
I would be very pleased for any help john