When key press "F5"
I refresh my collection colecao.View.Refresh();
...and lost focus of my datagrid
To back focus in row of datagrid I try this:
Focus()
on datagridFocusManager.SetFocusedElement
row.Focus()
If your using a CollectionView, I think you have to move the current selection using view.MoveCurrentTo(object)
or similar function.
Here you can find others, like view.MoveCurrentToFirst()
, etc.