I can save RV content in to the stream but
how can i save and restore RV states like caret pos, selected text, scrolling pos and etc.. ?
I tried to use this but it won't work
Code: Select all
procedure TForm1.cxButton1Click(Sender: TObject);
var Str: TMemoryStream;
begin
RegisterClass( TcxTRichViewEdit ) ;
RegisterClass( TcxInnerTRichViewEdit ) ;
// TcxInnerTRichViewEdit
Str:= TMemoryStream.Create;
Str.WriteComponent( cxTRichViewEdit1 );
Str.Position := 0;
cxTRichViewEdit1 := Str.ReadComponent(nil) as TcxTRichViewEdit;
Str.Free;
end;