|
-
Oct 31st, 2000, 09:10 PM
#1
Thread Starter
Lively Member
You can use the RowContaining and ColContaining properties to determine which row has been highlighted via a mouse click. See below.
Private Sub grdPending_MouseUp(Button As Integer, Shift As Integer, X As Single, Y As Single)
Dim ThisRow As Integer, ThisCol As Integer
Dim SelectedPendingJob as integer
ThisRow = grdPending.RowContaining(Y)
ThisCol = grdPending.ColContaining(X)
'Row selector clicked
If ThisRow >= 0 And ThisRow < grdPending.VisibleRows And _
ThisCol = -1 Then
'This gets me the value of the first column in the highlighted row, which I then further process
SelectedPendingJob = grdPending.Columns(ThisCol + 1).CellValue(grdPending.RowBookmark(ThisRow))
end sub
Hope this is what you are looking for.
Adrian.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|