Показать сообщение отдельно
  #5  
Старый 01.02.2009, 07:06
Аватар для Karsh
Karsh Karsh вне форума
Активный
 
Регистрация: 22.09.2007
Адрес: SPb
Сообщения: 228
Версия Delphi: 7, 2009, XE2
Репутация: 70
По умолчанию

а если так:

Код:
procedure TForm1.Button1Click(Sender: TObject);
var
  myFile: TextFile;
  s, buf: string;
begin
  AssignFile(myFile, 'file.txt');
  Reset(myFile);
  while not eof(myFile) do
  begin
    Readln(myFile, s);
    if s = '#3' then s:= '&3';
    buf:= buf + s + #13#10;
  end;
  CloseFile(myFile);
  Rewrite(myFile);
  Writeln(myFile, buf);
  CloseFile(myFile);
end;
Ответить с цитированием