Hi
I am working on VS2010 mixed-programing and use the Intel Compiler / VisualStudio (Intel Parallel 2015) to compile my project in VS 2010.
#include <conio.h> #include <string.h> //#define readfile readfile_ extern void readfile(char*, int*); int main() { int n, count; char Fname[9]; char Name[10]; strcpy(Fname,"AMIN.for"); fprintf( stderr, "%s\n", Fname); readfile( Fname, &n , strlen (Fname)); fprintf( stderr, "n = %d\n", n); // fprintf( stderr, "%s\n", Name); getch(); return 0; } subroutine - Lib fortran: subroutine readfile( fname1, m ) character fname1*(*) integer m integer iounit,i iounit=15 write(*,*) fname1 c10 format (a9) open(iounit,file = fname1,action='read') read (iounit,*) m c20 format (i10) write(*,*) m close(iounit) return end subroutine
My program is compiling on Linux but not compiling in windows(VS) I don't know what happen exactly. Thanks