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

EXE not working

PaulG1
Beginner
1,231 Views

I have been using INTEL fortran since 2018.  I have had parallel studio for some time.  I make both EXE and DLL that I have used for almost a decade.  Within the last month I bought an updated version of the fortran compiler and i use it with visual studio 2019.

To make an executable based upon F90 files I used before and still work on the computer right next to me, I created a new project as an empty project and then I populated all of the needed files into the appropriate directory.

All of the project compiler settings are as they should be based upon what they were before and what appears to be right.

When I click run without debugging from within Visual Studio, the code runs EXACTLY as it should and produces the results that it should.

When I grab the EXE from within the X64 folder and move to another folder on the SAME MACHINE, double clicking the EXE spawns a box saying it cannot find the entry point related to a DLL and this has nothing to do with a DLL that, I agree, requires some lines about entry point.

The error is about quiet_code or something like this.

Why does the EXE not work as it should work?

Any help appreciated.

 

 

0 Kudos
4 Replies
jimdempseyatthecove
Honored Contributor III
1,168 Views

This sounds like the runtime environment has not been setup.

Experiment first

Open up the oneAPI (or older Parallel Studio x64) command prompt. Navigate to the directory of the exe, then run the exe.

Note, this is not the Windows cmd prompt as this does not setup the environment variables.

 

If this works, then, write a batch program:

 

call "C:\Program Files (x86)\Intel\oneAPI\setvars.bat"

yourProgramHere.exe

 

Note, your path to setvars.bat will differ if you are using Parallel Studio.

Alternatively, you can locate the missing Intel .dll's, change the batch file to:

 

set PATH=%PATH%;"ThePathToTheDllHere"

yourProgramHere.exe

 

Place the batch file in the same directory as the .exe and then make a shortcut to the batch file on your desktop.

 

Jim Dempsey

andrew_4619
Honored Contributor III
1,133 Views

Is this a debug build? The debug run time is only set up if you run in VS.

0 Kudos
JohnNichols
Valued Contributor III
790 Views

Moving a Fortran exe file is a pain, it is always better to just have a directory for the data files and then read them from the program, which can be hidden. 

Trust me I tried this with student's and it is a pain. 

0 Kudos
andrew_4619
Honored Contributor III
704 Views

You are referring to debug builds John, I otherwise do not see what the moving pain might be?

0 Kudos
Reply