Incompatability between RTF colortables of Lebans RTF2 and Access RTF export function

  • Thread starter Thread starter Bas van der Doorn
  • Start date Start date
B

Bas van der Doorn

Hello,

When exporting an Access report as RTF document, Access will create a
colortable like this:

{\colortbl\red0\green0\blue0;\red255\green255\blue255;}if black and white
are the only colors used.

The Lebans RTF2 control creates a colortable like this:

{\colortbl ;\red0\green0\blue0;} if black is used as textcolor

The problem is that when RTF code is taken from Lebans control it will set
the front text color to cf1, which is color table index 1, which is white in
the Access color table. Since Access report text uses cf0 to indicate black,
it is very difficult to mix Access report text with Lebans RTF code. One
would have to change all the cf1 instances to cf0 in the RTF code for this
to work. Is there anyone who might know how to alter the color table Access
generates, or change the one generated by Lebans RTF control?

Thanks a lot,

Bas
 
The RTF2 control is created directly from the same DLL that Wordpad and
MS Word both use. Any incompatability you are experiencing is internal
to MS Access and the methods it uses to create the exported RTF file..

--

HTH
Stephen Lebans
http://www.lebans.com
Access Code, Tips and Tricks
Please respond only to the newsgroups so everyone can benefit.
 
Back
Top