I am writing a program which displays a series of incidents from a log file in date order into a rich text box. I want to highlight the incident header in a color based on the type of incident with the text of the incident in black. The format looks like this:
INCIDENT TYPE 01/01/2005 user name (This is the header)
Text of incident
INCIDENT TYPE 01/01/2005 user name
Text of incident
... and so on.
I am loading the data into an array as below to fill the RTB.
Line(0) = "Header"
Line(1) = "Text"
Line(2) = "Header"
......and so on?"
RichTextBox1.Lines = Line
How can I cause each header line to be highlight in say red and bold with the text in standard black. I have only been able to get the text in all one color or another. Thanks in advance for any suggestions.
W. C. Wolff
INCIDENT TYPE 01/01/2005 user name (This is the header)
Text of incident
INCIDENT TYPE 01/01/2005 user name
Text of incident
... and so on.
I am loading the data into an array as below to fill the RTB.
Line(0) = "Header"
Line(1) = "Text"
Line(2) = "Header"
......and so on?"
RichTextBox1.Lines = Line
How can I cause each header line to be highlight in say red and bold with the text in standard black. I have only been able to get the text in all one color or another. Thanks in advance for any suggestions.
W. C. Wolff