See attached.
this is wonderful! thanks a lot vbaInet.
i just modified a bit, because when i tried to resize the listview window until it shows only three items out of ten, the window didn't scroll though the item is highlighted, what i did is this:
Code:
Private Sub txtSearch_Change()
If Len(Me.txtSearch.Text & vbNullString) <> 0 Then
With rs
.FindFirst "Forename LIKE '*" & Me.txtSearch.Text & "*'"
If Not .NoMatch Then
lvSrch.ListItems(.AbsolutePosition + 1).Selected = True
[COLOR=blue]' ************* i add this line **************[/COLOR]
[COLOR=blue] lvSrch.ListItems(.AbsolutePosition + 1).EnsureVisible[/COLOR]
[COLOR=blue] '***************************************[/COLOR]
End If
End With
End If
End Sub
and it works fine, again thanks a lot.