textbox...

I'm using VB6 (professional edition).

If I have a textbox and multiline property is true. Then I add lines in textbox and new line goes always below the previous one. When there is more lines than there is room in a textbox, I don't see anymore those newest lines.
I have to use scrollbars to see those lines.

What I have to do so that I can see always those newest lines?

Thanks in advance!
majalaAsked:
Who is Participating?

[Webinar] Streamline your web hosting managementRegister Today

x
 
corvanderlindenConnect With a Mentor Commented:
Use:

txtEditor.Text = txtEditor.Text & "some string"

txtEditor.SelStart = Len(txtEditor.Text)
txtEditor.SelLength = 0

This positions you at the end of the text. The last line added should be visible
0
 
corvanderlindenCommented:
Use:

txtEditor.Text = txtEditor.Text & "some string"

txtEditor.SelStart = Len(txtEditor.Text)
txtEditor.SelLength = 0

This positions you at the end of the text. The last line added should be visible
0
 
KDivadCommented:
Set the scrollbar property to 1, 2 or 3 depending on whether you want horizontal, vertical or both. Unfortunately, this isn't available at runtime, you must set this property at designtime.
0
 
majalaAuthor Commented:
Thanks corvanderlinder!

If send your Comment as an answer so I can give you your points.

0
All Courses

From novice to tech pro — start learning today.