Microsoft Office Forums Word 16/19 change font and outside border color (same color) eg is red change to pink

Go Back   Microsoft Office Forums > >

Reply
 
Thread Tools Display Modes
  #1  
Old 12-03-2019, 11:50 PM
jec1 jec1 is offline Word 16/19 change font and outside border color (same color) eg is red change to pink Windows 7 32bit Word 16/19 change font and outside border color (same color) eg is red change to pink Office 2013
Advanced Beginner
Word 16/19 change font and outside border color (same color) eg is red change to pink
 
Join Date: Jan 2012
Posts: 52
jec1 is on a distinguished road
Default Word 16/19 change font and outside border color (same color) eg is red change to pink

Hi everyone


Looking for macro to change Word 2016 document (example attached) the font color for the text and outside border at same time for entire document. There are other 1 row tables each with different colour for a particular party. In this instance it is the Red Table Row and Text we wish to change.


1 row table
Text is red
Outside Table Border is Red
Attached Files
File Type: docx QUESTION.DOCX (41.7 KB, 2 views)
Reply With Quote
  #2  
Old 12-04-2019, 12:51 AM
macropod's Avatar
macropod macropod is offline Word 16/19 change font and outside border color (same color) eg is red change to pink Windows 7 64bit Word 16/19 change font and outside border color (same color) eg is red change to pink Office 2010 32bit
Administrator
 
Join Date: Dec 2010
Location: Canberra, Australia
Posts: 19,642
macropod is a splendid one to beholdmacropod is a splendid one to beholdmacropod is a splendid one to beholdmacropod is a splendid one to beholdmacropod is a splendid one to beholdmacropod is a splendid one to beholdmacropod is a splendid one to beholdmacropod is a splendid one to behold
Default

Try, for example:
Code:
Sub Demo()
Application.ScreenUpdating = False
Dim Tbl As Table, Cll As Cell
For Each Tbl In ActiveDocument.Tables
  For Each Cll In Tbl.Range.Cells
    With Cll
      If .Range.Font.Color = RGB(255, 0, 0) Then
        .Range.Font.ColorIndex = wdPink
      End If
      If .Borders.OutsideColor = RGB(255, 0, 0) Then
        .Borders.OutsideColorIndex = wdPink
      End If
    End With
  Next
Next
Application.ScreenUpdating = True
End Sub
__________________
Cheers,
Paul Edstein
[MS MVP - Word]
Reply With Quote
  #3  
Old 12-04-2019, 11:32 PM
jec1 jec1 is offline Word 16/19 change font and outside border color (same color) eg is red change to pink Windows 7 32bit Word 16/19 change font and outside border color (same color) eg is red change to pink Office 2013
Advanced Beginner
Word 16/19 change font and outside border color (same color) eg is red change to pink
 
Join Date: Jan 2012
Posts: 52
jec1 is on a distinguished road
Default Word 16/19 change font and outside border color (same color)

Hi Macropod
Many thanks.
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
VBA change font color to background color donaldadams1951 Word VBA 6 05-31-2018 04:36 PM
How to change the font color of specific text within a Word table cell epid011 Word Tables 2 05-15-2017 05:21 PM
Word 16/19 change font and outside border color (same color) eg is red change to pink change font color in word vacjan48 Word 2 11-16-2015 10:12 PM
Word macro doesn't change font color Spideriffic Word VBA 8 11-04-2015 03:47 AM
Word 16/19 change font and outside border color (same color) eg is red change to pink How to change the color of Character Border? tinfanide Word 4 10-27-2012 06:35 AM


All times are GMT -7. The time now is 12:22 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2019, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2019 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft