MSHFlexGrid / MSFlexGrid right click select row

Harkon
01-10-2005, 05:26 AM
Is it possible to select a row in one of those two FlexGrids using the right button click?

Private Sub MSHFlexGrid1_MouseUp(Button As Integer, Shift As Integer, x As Single, y As Single)
If Button = vbRightButton Then
MsgBox "Row: " & MSHFlexGrid1.Row
End If
End Sub

it always gives me the same row and I would like to make a seperate selection using right click for a popupmenu.

any help would be appreciated.

Flyguy
01-10-2005, 07:42 AM
use: MSHFlexGrid.MouseRow

Harkon
01-10-2005, 08:08 AM
great, many thanxs I wasn't aware of this property. the following does the job

If Button = vbRightButton Then
'select row
MSHFlexGrid1.Row = MSHFlexGrid1.MouseRow
Call MSHFlexGrid1_SelChange

Me.PopupMenu mnuRightClickCustomerList
End If


thanxs again :)

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum