On 19 apr 2006, at 15.29, Barry Traver wrote:

The Language Reference says this concerning an EditField:

"Setting ScrollPosition to the last line or beyond the last line will simply move the vertical scrollbar's thumb to the bottom, not necessarily displaying the last line at the top of the EditField."

But when I set the ScrollPosition to 9999, my EditField goes blank. Is that what is meant by "not necessarily displaying the last line at the top of the EditField"? I don't care whether the last line is displayed at the top of the EditField or not, but I do want it to be displayed.

When the EditField goes blank, if I click on the inside of the EditField nothing happens, but if I click on the Scrollbar "thumb" I get the text again (the result I wanted without having to click on the "thumb").

The reason I use 9999 is that I've found no way to compute the actual last line of the contents of an EditField. I can't just count the number of EndOfLine markers, because some of the lines (if they're long enough and if there is no horizontal Scrollbar) take up more than one line.

Any advice?

Barry Traver


Use something like this:

dim sEnd as integer

sEnd = me.Text.len

me.selstart = sEnd


Sven E Olsson
[EMAIL PROTECTED]
http://www.xhtmlsoft.com
feed://www.xhtmlsoft.com/rss/rss.xml


_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

Reply via email to