Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

textbox autoscroll

Status
Not open for further replies.

Miquella

Programmer
Mar 11, 2005
41
US
Does anyone know if it is possible to autoscroll a textbox? I'm trying to create a console of sorts, so that you can look at your command history, but I need the history text to stay at the last command entered. Right now, when it adds the text to the textbox, or when the textbox looses focus, it scrolls back to the top of the text. Any ideas?

-Bean
"Everything should be made as simple as possible, but not simpler." -Albert Einstein
 
have a look at
thread702-255626

Hope this helps
Hymn
 
Not quite what I'm looking for... I'm not just trying to marquee text, I actually want to use the scroll bar on the text box when it's in focus. It's a multi-line text box that I want to stay at the bottom/end of the text after the control looses focus. But currently it jumps back to the beginning/top of the text. Does that make sense?

-Bean
"Everything should be made as simple as possible, but not simpler." -Albert Einstein
 
You may try to play with the SelStart property.

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
.. and a really simple way would be to concatenate the new text to the BEGINNING followed by vbCrLf. Prefix it with now() and no fancy code will be needed.
Simon Rouse
 
Good idea DrSimon, that's one thing I had considered, but wanted to know if there's a different way.

Also good suggestion PH, but the control has to have focus to set the SelStart, and as soon as it looses focus, it reset's the box.

Thank you very much for your suggestions so far! If any has any more suggestions, please post them.

-Bean
"Everything should be made as simple as possible, but not simpler." -Albert Einstein
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top