procedure TForm1.Button1Click(Sender: TObject);
var
rs: TResourceStream;
ms: TMemoryStream;
begin
rs := TResourceStream.Create(HInstance, ClassName, RT_RCDATA);
try
ms := TMemoryStream.Create;
try
ObjectBinaryToText(rs, ms);
ms.Seek(0, 0);
memo1.Lines.LoadFromStream(ms);
finally
ms.Free;
end;
finally
rs.Free;
end;
end;
|