Option Explicit
Sub Macro6666()
Dim r As Range
Dim i As Long
Dim j As Long
Set r = Selection
With r
.Clear
.Value = 1
.Font.ColorIndex = 2
For i = 1 To r.Rows.Count
For j = 1 To r.Columns.Count
.Item(i, j).BorderAround , _
xlThin, xlColorIndexAutomatic
Next
Next
End With
End Sub