Imports System.Windows.Forms
Imports Infragistics.Win
Imports System.Diagnostics
Private Sub UltraGrid1_MouseMove(ByVal sender As Object, ByVal e As MouseEventArgs) Handles UltraGrid1.MouseMove
If IsPointOverUltraGridActiveRow(New Point(e.X, e.Y)) Then
Debug.WriteLine("Over Active Row")
Else
Debug.WriteLine("Not Over Active Row")
End If
End Sub
Private Function IsPointOverUltraGridActiveRow(ByVal pt As Point) As Boolean
Dim hitElement As UIElement = Me.UltraGrid1.DisplayLayout.UIElement.ElementFromPoint(pt)
If hitElement.HasContext(Me.UltraGrid1.DisplayLayout.ActiveRow) Then
Return True
Else
Return False
End If
End Function