Re: Richedit chars


[ DelphiLand ]

Posted by webmaster Guido on July 08, 2004

In Reply to: Re: Richedit chars posted by WAllison

: : I'd like to go through ALL of the characters in a RichEdit. My problem is that when I sum the length of all the lines, I always get less than with the GetTextLen function. I think it is due to the fact that the Length() does not count the #10#13 chars at the end of each line. Is there a way to count those too?

:
: why not just use RichEdit.Lines.Text;
-----------------

Note by webmaster Guido:
RichEdit.Lines.Text gives you ONE string with the entire text-contents of the RichEdit, including the control characters CR and LF (code #10 and #13).

Each RichEdit.Lines[N] on the other hand, like for example RichEdit.Lines[0] for the first line, only returns the text of that line, *without* the (possible) CR and LF at the end of it.


Related Articles and Replies:


[ DelphiLand FAQ ]