
EOF marker problem reading file
Open your file in Binary mode and get the whole lot in one go. You can then
examine the file at leisure:
Dim b() As Byte
Dim flen As Long
Dim fn As Integer
fn = FreeFile
Open "c:\mybigfile" For Binary As fn
flen = LOF(fn)
ReDim b(1 To flen)
Get fn, 1, b()
Close fn
The file data will now be in the byte array b(1) to b(flen)
Mike
Quote:
> I am writing some code to encrypt program, data, and help files for
> distribution on the Internet. However, I seem to be hitting an EOF
> marker. For example, I get an error 62 "Input past end of file" when I
> try to read the first 1000 bytes of a file. The input files are all
> well over 100,000 bytes. Any suggestions?
> =============================================
> William E. Buntain
> C&C Software