Link to home
Start Free TrialLog in
Avatar of Kane070698
Kane070698

asked on

Scrolling textboxes/picture boxes

I've got a program that automatically adds text to a picture box.  (I've tried with multiline textboxes also, with no effect).
I want it, when it gets to the bottom of the box, to automatically scroll up to keep the bottom-most line at the bottom of the textbox.  No matter what I've tried, it goes off the bottom and the view remains at the top...
Please help... I'm at a total loss.... :(
Avatar of waty
waty
Flag of Belgium image

Avatar of Kane070698
Kane070698

ASKER

It looks like that creates a scrollable picture box, but I'm still at a loss on understanding it... :(  no picture is put in the picture box in question.  Just lines of text appended to the end of it.  The problem is that I need to have it scroll up automatically with each new line appended to it...  (like.. in a dos window)  
Perhaps a textbox or something similar to that would be more suitable?  I'm still flexible at this point as to how it's done..  (doesn't *have* to be a picture box)
You could use a listbox. I do this in a listbox to have logfile of some applications.
Ok, I tried it out...  looks like a listbox may suit my needs better, but from VB's online help, I still can't figure out how to get it to keep the scroll at the bottom instead of parked at the top...
I did a simple test using a FOR loop, and add the counter to the list box...  To add more items than fit on the box....  It remained parked at the top instead of keeping the most recent entry in view in the bottom...
I'll re-open this in case someone else has an answer.... :)
To add at the top
  List1.AddItem "Test", 0

To add at the bottom
  List1.AddItem "Test", List1.ListCount
Thanks, but the view still remains firmly parked at the top of the list...
re-opening....
ASKER CERTIFIED SOLUTION
Avatar of jbil
jbil

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
That's got it...   Thanks....

A little tinkering, and I might be able to get rid of the blue selection highlight... :)  

I'm sorry....  I didn't notice-different person....
Many thanks to you too, waty....   I wish I could split the points... :)
No problem, I will probably respond to a further question coming from you.... :)
Re:   A little tinkering, and I might be able to get rid of the blue selection highlight... :)  



List1.Selected(List1.ListCount - 1) = False