Listview ItemSelectionChanged vs SelectedIndexChanged events

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

    Listview ItemSelectionChanged vs SelectedIndexChanged events

    The listview events "ItemSelectionC hanged" and "SelectedIndexC hanged" events
    appear to both fire when someone clicks on a different item in a listview.
    Is there some reason to use one event over another?



    Thanks,

    Dean S


  • Dave Kreskowiak

    #2
    RE: Listview ItemSelectionCh anged vs SelectedIndexCh anged events

    There's no reason to use either event that's dictated by the control, no.
    Which you use depends on the requirements of your own code.

    ItemSelectionCh anged will return the instance of the item who's selection
    has changed, where as SelectedIndexCh anged will just notify you that a
    selection change was made. It won't tell you which item changed.

    --
    <i><b>RageInThe Machine9532</b></i><font size="-2">
    "<i>...a pungent, ghastly, stinky piece of cheese!</i>" <b>-- The Roaming
    Gnome</b></font>


    "Dean Slindee" wrote:
    The listview events "ItemSelectionC hanged" and "SelectedIndexC hanged" events
    appear to both fire when someone clicks on a different item in a listview.
    Is there some reason to use one event over another?
    >
    >
    >
    Thanks,
    >
    Dean S
    >
    >
    >

    Comment

    Working...