Sets the color of selected text in a RichTextEdit control.
RichTextEdit controls
rtename.SetTextColor ( colornumber )
Argument |
Description |
---|---|
rtename |
The name of the RichTextEdit control in which you want to set the color of selected text |
colornumber |
A long specifying the color of the selected text |
Integer. Returns 1 if it succeeds and -1 if an error occurs.
For more information about calculating color values, see RGB.
This example sets the selected text in RichTextEdit rte_1 to dark red:
rte_1.SetTextColor(RGB(100, 0, 0))