Text File: Returning To Beginning?

  • Thread starter Thread starter PeteCresswell
  • Start date Start date
P

PeteCresswell

Got a handle to a text file - passed from a calling routine.

The handle has read activity against it (e.g. "Line Input
#theFileHandle, myLine) performed by other routines.

I want to go back to the beginning of the file and copy everything
except the header and trailer records to a new file.

I guess the no-brainer is to open the already-open file again under
another handle - in which case I would know that I am at the first
record.

Is there a more straightforward way?

i.e. Can I issue a command like ".Position" or ".MoveFirst" against
the existing file handle?
 
Is there a more straightforward way?

I withdraw the question.

Was keeping an array of text file info and it *seemed* like a good
idea to keep the file handles in it.

Seems to me like I was trying to fool Mother Nature...... So I changed
over to just storing the complete path and re-opening the file each
time I need it.
 
Back
Top