I'm trying to load RVF from a stream into table cells, but the method (LoadRVFFromStream) seems to have a lot of parameters which aren't documented in the help file, such as Color, Background and Layout. Could you explain what these are, or give an example of how to load RVF from a stream into an empty table cell in a TRichViewEdit?
Cheers,
Martin
Load RVF into table cells
-
- Site Admin
- Posts: 17557
- Joined: Sat Aug 27, 2005 10:28 am
- Contact:
Pass any TColor value and two nils as additional parameters.
But there is a problem: cells do not support merging style collections.
That means that:
1) RVF file must have the same collection of styles as TRVStyle used by TRichView containing the table
2) RVFTextStylesReadMode and RVFParaStylesReadMode properties of this TRichView must be set to rvf_sIgnore before loading RVF into cell.
This problem can be solved by loading RVF in a hidden TRichView linked to the same RVStyle, then copying from this TRichView to cell. Example can be found in Demos\Delphi\Assorted\Fields\MailMerge2 demo
But there is a problem: cells do not support merging style collections.
That means that:
1) RVF file must have the same collection of styles as TRVStyle used by TRichView containing the table
2) RVFTextStylesReadMode and RVFParaStylesReadMode properties of this TRichView must be set to rvf_sIgnore before loading RVF into cell.
This problem can be solved by loading RVF in a hidden TRichView linked to the same RVStyle, then copying from this TRichView to cell. Example can be found in Demos\Delphi\Assorted\Fields\MailMerge2 demo
-
- Posts: 131
- Joined: Mon Aug 29, 2005 12:03 pm
-
- Posts: 131
- Joined: Mon Aug 29, 2005 12:03 pm
I seem to have a working solution to this, explained here:
http://www.trichview.com/forums/viewtop ... =8874#8874
(Not a solution to the table cell problem; it's a solution to the issue I was trying to solve with tables, but which is better solved using paragraph formatting.)
http://www.trichview.com/forums/viewtop ... =8874#8874
(Not a solution to the table cell problem; it's a solution to the issue I was trying to solve with tables, but which is better solved using paragraph formatting.)