Information générale
Catégorie:
Contrôles ActiveX en VFP
There's certain header information in the RTF file that established what fonts and colors that you are using in your file. That said, what I did was to place the contents of the file into a character variable and assigned that to the RTF control's TextRtf property. Ie. ThisForm.oleRtfControl.Object.TextRtf = lcRtfStr.
For Font control Bold, Underline, Italics, you use the \b \u \i identifiers before the word/words that you want to change the attributs of. Then when you want that attribute turned off, you use \b0 \i0
Here's some sample code from my app that might help.
lcRtfStr = lcRtfStr + "\b\ul\i " + ALLTRIM(STR(c_results.counter)) + ". " + lcTitle + " " + lcDate + " " + lcRecType + "\b0\i0\par"
HTH
-Matt
Précédent
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement