Dim myR As Range
Set myR = Range("A1:A3")
myR.Borders(xlEdgeLeft).LineStyle = xlContinuous
myR.Borders(xlEdgeTop).LineStyle = xlContinuous
myR.Borders(xlEdgeBottom).LineStyle = xlContinuous
myR.Borders(xlEdgeRight).LineStyle = xlContinuous
myR.Borders(xlInsideHorizontal).LineStyle = xlNone
You can also set the line weight and color:
myR.Borders(xlEdgeLeft).Weight = xlThin
myR.Borders(xlEdgeLeft)..ColorIndex = xlAutomatic
etc.
HTH,
Bernie
MS Excel MVP
"bobens_83" <(E-Mail Removed)> wrote in message
news:033D4D21-355C-4A5D-9E1F-(E-Mail Removed)...
> Hi. How to set a solid border for range, not for each cell. For example
>
> Range("A1:A3")
>
> Greetings and thanks for help
|