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!

To put the question more simply

Status
Not open for further replies.

Frank72

Technical User
Nov 13, 2001
57
0
0
IE
If i have a double columned listbox how could i fill one text box with column1 and an other textbox with column 2?

surely this is possible!!

thank you

Frank
 
Hi Frank!

Try this in a command button click or in the afterupdate of the list box:

Dim intRow As Integer

For intRow = 0 To Me!YourListBox.ListCount - 1
If Me!YourListBox(intRow).Selected = True Then
Text1.Value = Me!YourListBox.Column(0, intRow)
Text2.Value = Me!YourListBox.Column(1, intRow)
Exit For
End If
Next intRow

hth
Jeff Bridgham
bridgham@purdue.edu
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top