Results 1 to 2 of 2

Thread: Listview & Pop-up Menu

  1. #1

    Thread Starter
    PowerPoster
    Join Date
    Nov 2002
    Location
    Manila
    Posts
    7,629

    Listview & Pop-up Menu

    I was planning on implementing a popup menu on my listview. Is there a way for a right click to select the item underneath the mouse pointer first before popping up the menu? So that the operations in the popup menu correspond to the item underneath.

    The only way I can do so right now is by implementing hover select but there's a delay. I was hoping there was a faster way.

  2. #2
    Lively Member
    Join Date
    Sep 2002
    Posts
    89
    The listview has a .HitTest method that returns the item based on an X and Y set of co-ordinates. Use the ListView_MouseDown event to determine if the mouse button was the right button, and pass in the X and Y into the .HitTest method

    - gaffa

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width