I have a 4 column listbox which is populated from a recordset.
I can locate the index of the selected row.
What is the syntax for reading the value of one of the columns?
Private Sub cmdSelect_Click() ' The listbox click event does nothing. I added this button to
detect the selected row.
Dim intCtr As Integer
Dim isSelected As Boolean
Dim intStop As Integer
intCtr = 1
For intCtr = 0 To lstApplicants.ListCount - 1
isSelected = lstApplicants.Selected(int
Ctr)
If isSelected Then
intStop = 8
lstApplicants.ItemData (intCtr) ' returns the data from column 0
' ??? Return the value from column 1, col 2, etc.
Exit For
End If
Next
End Sub
Thanks,
Start Free Trial