Convert richview files to rtf

General TRichView support forum. Please post your questions here
Sergey Tkachenko
Site Admin
Posts: 15239
Joined: Sat Aug 27, 2005 10:28 am

Re: Convert richview files to rtf

Post by Sergey Tkachenko »

The reason of this problem is definitely a mismatch of Unicode/Ansi text.
3 things must be in sync:
- Unicode property of text style
- rvioUnicode in ItemOptions
- text format ("raw Unicode"/Ansi)

I thought something is wrong is at the moment of insertion, but this code seems to be correct.
Try using RVInsertString (or RVInsertStringA/RVInsertStringW) from RVInsertItems.pas (if you want to insert in existing paragraph, ParaNo parameter must be -1) instead of this code.

There is another possibility: styles are changed after field replacement.
If using RVInsertString does not help, please create a simple project reproducing this problem and send it to me.

Post Reply