Word VB

tp2468

New Member
Joined
Mar 5, 2009
Messages
45
Apologies if this is in the wrong section but I thought it is something that you guys would be able to answer. I have a large word document, with serveral sections throughout the document with font colour red with the rest of the document being of font colur black.

I need to change every red character to green. I have tried recording macros but am unable to edit them to get them to do this. Any ideas or help would be appreiciated.

Regards

Tom
 

Excel Facts

Bring active cell back into view
Start at A1 and select to A9999 while writing a formula, you can't see A1 anymore. Press Ctrl+Backspace to bring active cell into view.
Hi Tom,

Try:
Rich (BB code):

Sub ReplaceFontRedToGreen()
  With ActiveDocument.Content.Find
    .Text = ""
    .Replacement.Text = ""
    .ClearFormatting
    .Replacement.ClearFormatting
    .Format = True
    .Font.Color = wdColorRed
    .Replacement.Font.Color = wdColorGreen
    .Wrap = wdFindContinue
    .Forward = True
    .Execute Replace:=wdReplaceAll
  End With
End Sub

Regards,
Vladimir
 
Last edited:
Upvote 0
For me it replaces the bullet’s color as well.
May be the bullet’s color is not strong wdColorRed but rather wdColorDarkRed or Red composited color?
See details on this link: How to Find and Replace a Font Color
 
Upvote 0

Forum statistics

Threads
1,225,400
Messages
6,184,761
Members
453,255
Latest member
excelbit

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top