Set Selected Item
Visual Basic
3
Posts
3
Posters
0
Views
1
Watching
-
Hi how can I set the item that is selected in a listview? Thanks mosquitooth
-
Hi how can I set the item that is selected in a listview? Thanks mosquitooth
-
Hi how can I set the item that is selected in a listview? Thanks mosquitooth
Simple:
ListView1.Item(<index>).Selected = True
But, the ListView control also has to have the focus for the select highlight to show. Use this:
ListView1.Select() ' Make the ListView the active control. ListView1.Item(<index>).Selected = True ' Select the items we want.
RageInTheMachine9532