TAdvDBMemo Text Length

When you have a single line text with 10 characters, length(advdbmemo.Lines.Text) as well as advdbmemo.Lines.Text.Length returns an incorrect number over 30.

I want to know the position of the last character. Am I doing it wrong?

Not sure what is causing this. Are there spaces added at the end of the line?

That's it. Yes, there are - the memo adds spaces as soon as you click somewhere in it. Happens when positioning the caret. Didn't realize it because I had only typed 10 characters.

Is it possible to turn that off and make it behave like a "normal" memo - caret can't be positioned where no character is?

Set AdvMemo.AutoExpand = false

1 Like

Thank you very much!

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.