I need to get the number of lines in a richtextbox relative to the richtextbox's width not the number of newline characters. Wordwrap is enabled in the richtextbox and I want to count all of the visible lines, not just the actual lines (made by pressing enter). How could I do this? I apologize if my question is not clear.

1 answers
The following code should count all the 'physical' lines in a richtextbox:
If the last or only line in the richtextbox is empty, then the code will not count it as a line.
answered 2 years ago by:
17279