Change the value of a Listview subitem

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a ListView box in my form which is populated by an array :

Dim item2 As New ListViewItem(index & ".")
item2.Checked = True
item2.SubItems.Add(r.description)
item2.SubItems.Add(r.host)

How can I change the value of these subitems afterwards?

For example:
I have 2 forms. One with the ListView box and one with some textfields to
enter some data (description, host, ...). After a user has entered the data
everything is stored in an array (r.xxxx) and two fields (description and
host) are shown in the ListView box as a reference. Now the user selects this
entry again and clicks the button "Edit". The second form opens again showing
all previously entered data and the user does some changes, eg. modifying the
"host" entry. After clicking OK the value for "host" in the ListView box
should be updated.
Everything works already (all forms, add, edit, remove, storing data (also
edited data) in an array, etc.). Only the update of the ListView is missing.
 
Back
Top