begin
  TT.Active := true;
  TT.First;
  M := TStringList.Create;
  Line := TT.Fields[0].DisplayName;
  For i := 1 to TT.FieldCount -1 do
    Line := Line + Delimiter + TT.Fields[i].DisplayLabel;
  M.Add(Line);
  while not TT.Eof do
  begin
    Line := TT.Fields[0].AsString;
    For i := 1 to TT.FieldCount -1 do
        Line := Line + Delimiter + StringReplace(StringReplace(TT.Fields[i].AsString,
          #13#10,' ',[rfReplaceAll]),#9,' ',[rfReplaceAll])     ;
    M.Add(Line);
    TT.Next;
  end;
  M.SaveToFile('newfile');end;