procedure TForm1.BtnGetClick(Sender: TObject);
var
bs: TBlobStream;
begin
bs := nil;
with Table1 do
try
open;
first;
bs := TBlobStream.Create(table1memo, bmread);
Richedit1.plaintext := false;
Richedit1.Lines.Loadfromstream(bs);
finally
bs.free;
close;
end;
end;
procedure TForm1.BtnPutClick(Sender: TObject);
var
bs: TBlobStream;
begin
bs := nil;
with Table1 do
try
open;
first;
edit;
bs := TBlobStream.Create(table1memo, bmwrite);
Richedit1.plaintext := false;
Richedit1.Lines.Savetostream(bs);
post;
finally
bs.free;
close;
end;
end;
|