Private Sub Worksheet_SelectionChange(ByVal Target As Range)
If Target.CountLarge > 1 Then Exit Sub
Dim P1 As Range, P2 As Range, P3 As Range, P4 As Range
If Target.Row > 1 Then Set P1 = Target.EntireColumn.Resize(Target.Row - 1) Else Set P1 = Target
If Target.Row < Rows.Count Then Set P2 = Target(2).Resize(Rows.Count - Target.Row) Else Set P2 = Target
If Target.Column > 1 Then Set P3 = Target.EntireRow.Resize(, Target.Column - 1) Else Set P3 = Target
If Target.Column < Columns.Count Then Set P4 = Target(1, 2).Resize(, Columns.Count - Target.Column) Else Set P4 = Target
Union(Target, P1, P2, P3, P4).Select
Target.Activate
End Sub