Just wondering if you are looking at this in the right context.

FileSize will give you the size in bytes which may be what you are looking
for.

If you just want to process the file and give feedback on how far they have
to go, then a simple percentage done in bytes may be better than line numbers.

Alternatively, if you wish to load the text file but want to check if there
are too many lines before you do it, then Fileize may be OK then too.

Then <TStrings>.LoadFromFile will place the entire file in a TStrings
object where .Count and numerous methods and properties are available for
processing.
1
Why the need top know the exact number of lines - does it matter?

Steve

---------------------------------------------------------------------------
    New Zealand Delphi Users group - Delphi List - [EMAIL PROTECTED]
                  Website: http://www.delphi.org.nz
To UnSub, send email to: [EMAIL PROTECTED] 
with body of "unsubscribe delphi"

Reply via email to