I do not know if it is the best way, but here is what I am doing:
private void myGrid_MouseDoubleClick(object sender, MouseButtonEventArgs e)
FrameworkElement element = myGrid.InputHitTest(e.GetPosition(myGrid)) as FrameworkElement;
if (element != null)
if (element.Parent is DataGridCell)
// Do Work here
I have to check if the element.Parent is DataGridCell because the hit test actually returns the TextBlock inside of the cell. I assue this would again get more complicated depending on what was added to the DataGridCell if you were using a Control Template
or Data Template, but I haven't gotten that far into my app yet.
So far it seems to work ok, but I just assumed there would be a built in way to tell if the double click was on a record. The grid I have used the most previously was the Dev Express grid for VCL. With those products, there was a hit test that could tell
you which portion of the grid you clicked on (Header, cell, etc.).