Displaying updated subitems in Listview

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Jack

    #1

    Displaying updated subitems in Listview

    Hello all,

    In code, I'm updating the text property of subitems in a Listview which is
    in Details view. This may be a dumb question, but I can't seem to find a good
    way to refresh the listview to show the changes. There is no database behind
    the listview. It's just me programatically loading it up with items and
    subitems.

    --------------------------------------------------------------
    An example of how subitems are modified is:

    Public MySub(lvItem as ListViewItem)

    lvItem.SubItems (0).Text = "Hello"

    End Sub

    --------------------------------------------------------------

    Displaying subitems when the listview is initially loaded is no problem at
    all. The issue is when they are edited as a result of events fired during
    user interaction with the application. And, I've confirmed in the debugger
    that the subitem text values are changed successfully. They just aren't
    displayed. Interestingly, when I fire the ResetText method on the form, the
    font changes made to subitems are shown, but the text isn't updated.

    I know the answer will make complete sense once it's conveyed to me, but at
    this point I've tried what I think makes logical sense and thought I'd stop
    killing time and ask someone who knows the answer.

    Thanks in advance!

    Jack


Working...