i have a listview with subitems namely NAME Age and Position. The positions are Driver, Conductor and Inspector. I have 3 textbox namely CountD, CountC, CountI. What i want is if i Click the Name in the listview where the position is driver, the CountD.text will display 1 and if i Click another name in the listview where the position is also driver, the CountD.text will display 2 and so on. Also in other two texboxes where there position is Conductor and Inspector. HELP ME PLEASE GODBLESS
Jump to Post
You will want to match things up.
Declare a class wide variable to reference the clicked item.
Private lviCurrent As New ListViewItem
Next you will want to set the item to the selected item (in the listview's click event)
If IsNothing(ListView1.SelectedItems) = …
All 4 Replies
We're a friendly, industry-focused community of 1.21 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.