I'm tyring to do this for a listView control, I want to figure out whether an item was dblClicked with the right mouse button or the left button.....
:rolleyes:
how can I do this?:)
I'm tyring to do this for a listView control, I want to figure out whether an item was dblClicked with the right mouse button or the left button.....
:rolleyes:
how can I do this?:)
CAN you fire a doubleclick event with a right click? I though only left click would fire a doubleclick.
yes it fires, that's my problemmo:D it's kind of stupid to perform a default action when the user double clicks with the LEFT button, so I have to check for the buttonQuote:
Originally posted by Edneeis
CAN you fire a doubleclick event with a right click? I though only left click would fire a doubleclick.
Well it's not pretty but it works, if you can't find a proper way:
VB Code:
Private lastbutton As MouseButtons 'as form level variable Private Sub ListView1_DoubleClick(ByVal sender As Object, ByVal e As System.EventArgs) Handles ListView1.DoubleClick Me.Text = lastbutton.ToString End Sub Private Sub ListView1_MouseUp(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles ListView1.MouseUp lastbutton = e.Button End Sub
tnx:) but I've thought of that way already. I was thinking that there is be a better way to do this. (I ThInkZ:D)
Actually now that I think about it didn't you have to do the same thing in VB6 to get the right double click?
Yes:D but I was thinking that VB.NET can do magic and stuff, that's why I'm looking for a way:pQuote:
Originally posted by Edneeis
Actually now that I think about it didn't you have to do the same thing in VB6 to get the right double click?