G Guest Jun 23, 2004 #1 Hi, i have un listview in a winform, multiselect = true. I would like to know which is the last item to select when it several item selected there. Best regards. Sylvain
Hi, i have un listview in a winform, multiselect = true. I would like to know which is the last item to select when it several item selected there. Best regards. Sylvain
A Allen Anderson Jun 24, 2004 #2 ListViewItem item; if ( listview1.SelectedItems.Count > 0 ) item = listview1.SelectedItems[ listview1.SelectedItems.Count-1 ]; That should get you the last selected item. Allen Anderson http://www.glacialcomponents.com mailto: allen@put my website url here.com
ListViewItem item; if ( listview1.SelectedItems.Count > 0 ) item = listview1.SelectedItems[ listview1.SelectedItems.Count-1 ]; That should get you the last selected item. Allen Anderson http://www.glacialcomponents.com mailto: allen@put my website url here.com
A Allen Anderson Jul 18, 2004 #3 I believe listview1.FocusedItem would get that for you then. Thanks for the answer, but I would like to know the last selected item by the mouse and key "CTRL". Thanks a lot.. Allen Anderson said: ListViewItem item; if ( listview1.SelectedItems.Count > 0 ) item = listview1.SelectedItems[ listview1.SelectedItems.Count-1 ]; That should get you the last selected item. Allen Anderson http://www.glacialcomponents.com mailto: allen@put my website url here.com Hi, i have un listview in a winform, multiselect = true. I would like to know which is the last item to select when it several item selected there. Best regards. Sylvain Click to expand... Click to expand... Click to expand...
I believe listview1.FocusedItem would get that for you then. Thanks for the answer, but I would like to know the last selected item by the mouse and key "CTRL". Thanks a lot.. Allen Anderson said: ListViewItem item; if ( listview1.SelectedItems.Count > 0 ) item = listview1.SelectedItems[ listview1.SelectedItems.Count-1 ]; That should get you the last selected item. Allen Anderson http://www.glacialcomponents.com mailto: allen@put my website url here.com Hi, i have un listview in a winform, multiselect = true. I would like to know which is the last item to select when it several item selected there. Best regards. Sylvain Click to expand... Click to expand... Click to expand...