Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
28446 Discussions

How to run *.exe file from Intel Visual Fortran

SEWON_K_
Beginner
376 Views

 

Dear Developers 

Acutally, I did migrate from Compaq Fortran to Intel Visual Fortran, 

Original code is like as follows in compaq fortran 

cmd = 'kalmansryu'

call system(cmd)

but it made errors in intel visual fortran. (kalmansry is exe file that was made from Matlab) 

How can I change 'call system'. Could you show me example? 

 

 

0 Kudos
3 Replies
mecej4
Honored Contributor III
376 Views

See your Fortran documentation. You have to add USE IFPORT, and note the correct invocation of the SYSTEM function: 

      result = SYSTEM (string)

The returned value is an integer.

0 Kudos
SEWON_K_
Beginner
376 Views

 

Dear mecej4 

I really appreciate your kind reply. Can IFPORT invoce external exe file? 

I reviewed fortran documentation but I didn't find good example and expalanation. Can you teach me the how to use ifport in this case? 

 

 

0 Kudos
mecej4
Honored Contributor III
376 Views

USE IFPORT is for the purpose of providing the correct interface to the SYSTEM() function. The Intel Fortran reference manual page for SYSTEM provides complete source code for an example of using this function.

0 Kudos
Reply