Recorded macros that add cell borders list an essay of properties for topedge, bottomedge, leftedge, rightedge, horozontal, inside....settings
It is way too much detail if you simply want full borders around your selection or range reference.
Here is the short version... You simply need 1 (or 2) lines for FULL or AROUND borders.
Please note that the .Borders property DOES NOT have arguments like the BorderAround property!
Code: Select all
Sub AddBorders()
Selection.Borders.Weight = xlThin
Selection.BorderAround ColorIndex:=3, Weight:=xlThick
End Sub