The ENABLERTF message is used to enable printing RTF codes in text, tables, headers, and footers. When ENABLERTF is enabled the report will print slower. All of the text must be surrounded by curly brackets {}. This feature allows you to customize the cells of a tables, and change fonts in the headers and footers.
Especially with large documents, there is a noticeable slowdown in printing when using ENABLERTF. |
Parameter | Description of Fields | Comments | Default |
---|---|---|---|
Parm1 – EnableRTF | <1> EnableRTF | 1=Enabled 0=Disabled | 0 |
The following table displays the most commonly used RTF codes.
Code | Description |
---|---|
\b | Bold |
\blue | Blue |
\bullet | Bullet (ANSI character 149) |
\cb | Background Color |
\f | Selected Font |
\fs | Font Size |
\g | Green |
\i | Italics |
\qc | Align Center |
\gl | Align Left |
\gr | Align Right |
\red | Red |
\sub | Subscript |
\super | Superscript |
\ul | Underline |
\uldb | Double Underline |
\ulhair | Hairline Underline |
\ulth | Thick Underline |
For a complete list of Microsoft supported RTF codes, follow this link.
* The following example shows how to use the ENABLERTF message to print bold * text in a header and a table. declare function Set_Printer stat = Set_Printer("START32") ; *start OIPI stat = Set_Printer("INIT") ;* Start printing * enable the RTF codes in printing. Stat = Set_Printer("ENABLERTF",1) ;* Enable RTF printing stat = Set_Printer("HEADER", @VM:"{This is a {\b bold} RTF header.}") stat = Set_Printer("TEXT", "This is a test.") stat = Set_Printer("ADDTABLE", "1440":@VM:"1440", "", "{Row {\b 1} Col {\b 1}}":@VM:"{Row {\b 1} Col {\b 2}}":@FM:"Row 2 Col 1":@VM:"Row 2 Col 2", "", "", 0, 7) stat = Set_Printer("TERM", 1) ;* End printing |