
01.02.2009, 07:06
|
 |
Активный
|
|
Регистрация: 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;
|