How can I fix the following code that draws rectangles around the cells ...?
Code: Select all
Sub Test()
Dim c As Range
For Each c In ActiveSheet.Range("B3:F3")
AddShape c
Next c
End Sub
Sub AddShape(rng As Range)
rng.Cells(1).Parent.Shapes.AddShape msoShapeRectangle, rng.Left, rng.Top, rng.Width, rng.Height
End Sub