Hey!
This is my code to select a random item in a listview:
It works fine, but when I use the arrow keys to select another item, the selection jumps to a whole different place...
Like, when I select item A manually, and then use that code to select random item B, and I press an arrow key, the listview jumps to item A again!
Sorry if you don't understand because it's hard to explain.
:wave:
This is my code to select a random item in a listview:
Code:
Dim tmp As Integer
tmp = Rnd() * ListView2.Items.Count - 1
ListView2.Items(tmp).Selected = True
ListView2.EnsureVisible(tmp)
Like, when I select item A manually, and then use that code to select random item B, and I press an arrow key, the listview jumps to item A again!
Sorry if you don't understand because it's hard to explain.
:wave: