Quote:
Originally Posted by
Jimmyd24
So in my Fortran program would I have to put $File where I am attempting to open the txt files?
No. The shell will evaluate the variable
$FILE and perform Variable Expansion to convert the variable into the actual filename.
If your program can handle arguments, the code would then use Parameter Expansion to evaluate the 1st, 2nd, 3rd argument, etc...
You absolutely shouldn't use the variable
$FILE in your fortran code, unless it is defined explicitly.
Also note that shell variables are case sensitive, and that
$FILE is
NOT the same as
$File
How do you execute the fortan program for a single file ??