ListView.GetItemAt Problem

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

    #1

    ListView.GetItemAt Problem

    Hi,

    VS.2005 Pro / VB.NET

    I find ListView.GetIte mAt(x,y) always returns 'Nothing' when the returned
    value would (if it worked) be a ListViewItem.

    However, when the returned value is ListViewSubItem , the ListViewItem is
    returned along with the ListViewSubItem .

    Is this a bug or am I doing something wrong?

    Thanks
    Harry


    Using the following code, when the first column (ListViewItem) is clicked,
    lvItem=Nothing, however the second column (ListViewSubIte m) lvItem along
    with the lvItem.ListView SubItem is returned correctly.

    Private Sub HandleMouseDown (ByVal sender As Object, ByVal e As
    MouseEventArgs) Handles ListView1.Mouse Down
    Dim lvItem As ListViewItem = ListVierw1.GetI temAt(e.X, e.Y)
    End Sub


Working...