[log in to unmask] said:
> Would that be the simplest way to achieve what I was trying though?
Sometimes it is not necessary to know before hand the exact number of records
and you can get by with just using the "END=label" argument to READ
Other times you can put this information in the last record of the file and just
read your way to the end of the file using the "END=label" approach and then,
now that you have your directory information you can do your reads
A third way to do this is to use standard file access libraries such as netCDF
and HDF.
A fourth way is to use an auxilliary file with this meta data (and possibly also
have it last in the file so that you can recreate your meta data on the fly and
also verify the meta data file with the last record)
A fifth way is to do what you did, but use a C function call to manipulate
the content of the first record to become the actual number of records.
/Nils
|