DevilAkuma
Active member
- Joined
- Oct 24, 2005
- Messages
- 37
- Programming Experience
- Beginner
Hello!
I'm working inside of a RichTextBox, and I need to change the color of a specific text. I can get the start very easy...
But I don't know how can I get the final of the line.
I've tried searching for the next carriage return...
But this doesn't work because (I don't know why) the RichTextBox keeps my new Color and It used to color the rest of the text... I select & colour the text with...
But the text is changed until the end of all...
Smeone knowshow can i do it?
Thanks in advance (and sorry about my English)
I'm working inside of a RichTextBox, and I need to change the color of a specific text. I can get the start very easy...
VB.NET:
Dim start As Integer = myRichTextBox.Find("text",0)
I've tried searching for the next carriage return...
VB.NET:
Dim end As Integer = myRichTextBox.Find(Chr(13),start))
VB.NET:
myRichTextBox.Select(start,end)
myRichTextBox.SelectionColor = Color.Green
But the text is changed until the end of all...
Smeone knowshow can i do it?
Thanks in advance (and sorry about my English)
Last edited: