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

No way to open a Non-standard file

WSinc
New Contributor I
409 Views

I am trying to open a file that was not generated by a Fortran app.

 

open (2,file="LAFA.mid", form='binary', access='sequential', &
action="read")

 

I thought there was a way to do this ?

I just want examine the contents of this file.

 

Has anyone written an article about this ?

0 Kudos
2 Replies
GVautier
New Contributor II
405 Views

Your statement seems OK and will open any file.

Then you must read it block by block into variable(s). Next, you must interpret the contents of these variables (convert to hexa, decode with adapted types if you know the structure of the file...)

0 Kudos
jimdempseyatthecove
Honored Contributor III
400 Views

Is your file located in the current directory?

Note, if running from MS Visual Studio, the "current" current directory is that of the solution as opposed to the location of the execuitable (Debug or Release folder). You can change the current directory in the Debug/Release property page.

Jim Dempsey

0 Kudos
Reply