Microsoft KB Archive/23838

Interlanguage Calling

PSS ID Number: Q23838 Article last modified on 02-24-1988

3.2 3.3x 4.0x MS-DOS

Question: Does FORTRAN provide interlanguage calling capability?

Response: Yes, both XENIX FORTRAN and MS-DOS FORTRAN allow you to link together subroutines that are written in Microsoft C, Pascal, or Assembler. Additionally, XENIX FORTRAN allows you to link BASIC subroutines; MS-DOS FORTRAN also allows this but requires QuickBASIC Version 4.00 or later. If you want to use languages that cannot be linked into your program as subroutines, you must use the EXEC or SPAWN command. These commands tell the operating system (XENIX or MS-DOS) to run the program as a child process. This child process can either overlay the parent process or return to the parent. However, no data can be shared between the parent and child processes because the linker cannot resolve their data references. Thus, a SPAWNed or EXECed program is essentially a standalone application that is called by your program, rather than by the person who typed its name at the system prompt.