View Single Post
 
Old 04-13-2025, 05:32 AM
gmaxey gmaxey is offline Windows 10 Office 2019
Expert
 
Join Date: May 2010
Location: Brasstown, NC
Posts: 1,617
gmaxey is just really nicegmaxey is just really nicegmaxey is just really nicegmaxey is just really nicegmaxey is just really nice
Default

I didn't get your error running Vikka's code. You can also try:

Code:
Sub BorderColor()
Dim oBrdr As Variant
Dim MyColor As Long
    Application.ScreenUpdating = False
    MyColor = 10027008 'InputBox("Specify color code", "Border Color")
    For Each oBrdr In Selection.ParagraphFormat.Borders
      With oBrdr
        .LineStyle = wdLineStyleSingle
        .LineWidth = wdLineWidth050pt
        .Color = MyColor
      End With
    Next oBrdr
   Application.ScreenUpdating = True
End Sub
__________________
Greg Maxey
Please visit my web site at http://www.gregmaxey.com/
Reply With Quote