Quantcast
Channel: VBForums - Visual Basic 6 and Earlier
Viewing all articles
Browse latest Browse all 21090

How do I select a line of text in RTB using the line number ?

$
0
0
Hi all

I hope someone can give me a simple solution.

In VB6 I have a RICHTEXT box on a form,

I want to be able to click on a line of text, to select all the text on that line, then change the colour of all text on that line

I have so far used "getlinenumber" to determine the number of the line that i click on.

I guess I could create a loop to scan through the text ( charachter at a time, from beginning to end ) to identify charachters that correspond to that line number, and change the individual characher colour one at a time, but it would be a clumsy way of doing it.

Does anyone know an easy way to select all the text on a particular line number ?

Thanks for any help

Regards

David

Viewing all articles
Browse latest Browse all 21090

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>