Macro to add horizontal double-border to single cell

J

jlarge

I just re-read my post and perhaps I wasn't too clear. The macro I found
applies a double-line border all around the cell. I want the border applied
horizontally on the bottom only. Thanks
 
L

Lene Fredborg

The following macro applies a double underline to the bottom of the selected
cell (if more cells are selected, the border is only applied to the first
cell):

Sub BorderCell()

If Selection.Information(wdWithInTable) Then

'Apply double bottom border to table cell
With Selection.Cells(1).Borders(wdBorderBottom)
.LineWidth = wdLineWidth050pt
.LineStyle = wdLineStyleDouble
End With

Else

MsgBox "Insertion point is not in a Word table"

End If

End Sub

--
Regards
Lene Fredborg
DocTools - Denmark
www.thedoctools.com
Document automation - add-ins, macros and templates for Microsoft Word
 
Top