I\'ve been held up on this for about a week, now, and have searched forum after forum for a clear explanation of how to send a char* from C to FORTRAN. To make the matter m
I always struggle with these interoperability features. I think that your interface should declare
CHARACTER(KIND=C_CHAR),DIMENSION(*) :: getlasterrormessage
and that, when you call the function, you pass a corresponding Fortran character variable with a length equal to or greater than the length of the array of C characters you expect to return.
Since you seem to have Intel Fortran, look through the code samples provided, they give a complete example for this.
I guess you know that what you have posted is not syntactically correct Fortran ?