Page 1 of 1

"LoadRVFFromStream" method failed?

Posted: Wed Oct 19, 2005 7:31 am
by SKY
Hi all,
1. I used "SaveRVFToStream" to save my "RichViewEdit" content into a stream, and Compress Stream to Save the file.
2.Read stream from file and decompress this Stream, and then use "LoadRVFFromStream" it from the stream, but the "LoadRVFFromStream" method is failed.
I uses ZLip.TCompressionStream Method to do compress.
Can you send me a tutorial to help me with this?
Ths

Posted: Wed Oct 19, 2005 12:34 pm
by Sergey Tkachenko
Make sure that you call Stream.Position := 0 before loading and RichViewEdit.Format after.
If it will not help, please save the content of this stream after decompression to a file and send this file to me ( svt@trichview.com )

to Sergey

Posted: Thu Oct 20, 2005 3:02 am
by SKY
Thanks
I make sure that call Stream.Position := 0 before loading and RichViewEdit.Format after. But problem is not solved.
I Sended a file to you.

thanks!

Posted: Sat Oct 22, 2005 2:53 pm
by Sergey Tkachenko
I received your file. It does not contain collections of text and paragraph styles, so it can be loaded only in TRichView having exactly the same collection of styles.

If these collection are saved inside the file, this file can be loaded in any TRichView. Right click TRichViewEdit in Delphi, choose "Settings" in the popup menu, select "Allow adding styles dynamically".