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 SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Programatically select the row in a listbox?

Status
Not open for further replies.

grobermatic

Technical User
Dec 21, 2002
153
0
0
GB
I'm trying to programatically select the last row in a list box.... but I can't work out how... any pointers??

Cheers

Craig

--------------------------------------------------------------------------------------------------------
"Time-traveling is just too dangerous. Better that I devote myself to study the other great mystery of the universe: Women!" .. Dr E. Brown (1985)
 
You can use code similar to this:

ListBoxName = ListBoxName.ItemData(ListBoxName.ListCount - 1)

PaulF
 
You may try something like this:
Me!theListbox.Selected(Me!theListbox.ListCount - 1) = True

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top