View Single Post
Join Date: Dec 2004
Posts: 2,413
Reputation: Comatose is a jewel in the rough Comatose is a jewel in the rough Comatose is a jewel in the rough Comatose is a jewel in the rough 
Solved Threads: 211
Team Colleague
Comatose's Avatar
Comatose Comatose is offline Offline
Taboo Programmer

Re: To position textbox scrollbar at bottom of text

 
0
  #8
Jan 21st, 2009
Well, Visual Basic and VBA (Visual Basic For Applications) are NOT the same. Visual Basic (And This Forum is VB 4/5/6, NOT .Net, which is also different [ie: VB express, VB 2005, VB 2008, etc]). That said, code that would often work in VB 6, such as the code I posted with sendmessage, will not work if you are in VBA (VB inside of Access). Now, you could normally get away with selecting and deselecting the listbox in Access, like so:
  1. Me.mylistbox.Selected(Me.mylistbox.ListCount - 1) = True
  2. Me.mylistbox.Selected(Me.mylistbox.ListCount - 1) = False
I believe I also read somewhere that you can pass the DESC sql key word to make it sort the data in the listbox by descending order, which automatically scrolls the listbox... but I haven't tried that.
Reply With Quote