Hi,
I try to replace text part of RichViewEdit1 by another text part of RichViewEdit2.
I use SetItemTextA but I loose #10 and #13 caracters.
Thank you for help
Regards
Replace text part of RichViewEdit1 by text part of RichViewE
-
- Site Admin
- Posts: 17566
- Joined: Sat Aug 27, 2005 10:28 am
- Contact:
Sorry, what do you mean by replacing text part?
If you want to copy document as a plain text (without all text and paragraph attributes, images, tables, etc.) use this code:
If you want to copy document as a plain text (without all text and paragraph attributes, images, tables, etc.) use this code:
Code: Select all
var Stream: TStringStream;
begin
Stream := TStringStream.Create('');
RichViewEdit1.SaveTextToStream('', Stream, 80, False, False);
RichViewEdit2.Clear;
RichViewEdit2.AddTextNLA(Stream.DataString, 0, 0, 0);
RichViewEdit2.Format;
Stream.Free;
end;
-
- Site Admin
- Posts: 17566
- Joined: Sat Aug 27, 2005 10:28 am
- Contact: