Mark, In recent years I have forsaken the old and trusty TextFile variable
to using TStrings. With TStrings, not only can I write to and read from
text files in a single call, but the contents are then already placed into
a ready made object for me to manipulate.

eg:

Var 
    Stuff: TStrings;
    i: integer;
begin
    Stuff := TStringList.Create;
    try
        Stuff.LoadFromFile(FileName);
        for i := 0 to stuff.Count - 1 do
            ShowMessage(Stuff[i]); // do things with the line
    finally
        stuff.free;
    end;
end;

Must easier and able to do lots of excellent things with it - for example,
by using the Values and Names properties, I can read and manipulate ini
files much easier than the inbuilt TIniFile object.

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