trichview.support
SaveTextToStream problems |
Author |
Message |
Yoerdes |
Posted: 05/25/2003 3:47:57 Hi, I want to get the contents of a TRichViewEdit as a simple string and use the following code to achieve this: procedure TForm1.Button1OnClick(Sender: TObject); begin Label1.Caption := GetPlainText; end; function TForm1.GetPlainText: string; var Stream: TMemoryStream; s: string; begin rve.SaveTextToStream('', Stream, 0, false, true); SetLength(s, Stream.Size); Stream.Read(s[1], Stream.Size); Result := s; end; If the text in the TRichViewEdit doesn't have any special items, it works as expected. But if there is a hyperlink included the result nonsense. No luck when setting TextOnly := false; either. Regards Yoerdes |
Powered by ABC Amber Outlook Express Converter