Problem reading data from a file (encounter EOF after second last record)
- From: nure123@xxxxxxxxx
- Date: Tue, 29 Jan 2008 00:28:19 -0800 (PST)
Hi Everybody,
I am reading data from a file. I know the number of records in the
file and can read all the records except for the last. Using IOSTAT
in the READ statement shows that EOF is encountered after reading the
second last record. I am baffled a bit. I think it has to do something
with the program which created the datafile in the first place, but I
do not want to touch that program as far as possible. Could anybody
pull me out of the problem.
(for example, following is the structure of my datafile. I can read
the second last line, but not the last)
0.00000000000000E+000 1 5.00E-008
5.00000000000000E-004 2 5.90E-008
1.08988019155737E-003 3 6.96E-008
1.78579747234089E-003 4 8.21E-008
2.60681311013423E-003 5 9.69E-008
3.57541483352048E-003 6 1.14E-007
4.71813277378826E-003 7 1.35E-007
6.06626612879065E-003 8 1.59E-007
7.65674045217803E-003 9 1.88E-007
9.53311904927169E-003 10 2.21E-007
1.17467961818472E-002 11 2.61E-007
Regards,
Nure
.
- Follow-Ups:
- Prev by Date: Re: Handling automation events in an Intel Visual Fortran Windows application
- Next by Date: Re: locate a value in an array
- Previous by thread: Handling automation events in an Intel Visual Fortran Windows application
- Next by thread: Re: Problem reading data from a file (encounter EOF after second last record)
- Index(es):