Thank you for being a valued part of the CNET community. As of December 1, 2020, the forums are in read-only format. In early 2021, CNET Forums will no longer be available. We are grateful for the participation and advice you have provided to one another over the years.

Thanks,

CNET Support

General discussion

word Macro help

Apr 16, 2007 4:56AM PDT

Hi,

I've been doing some editing in Word and was wondering how to automate some highly repetitive tasks I've been doing. I don't know if I need a macro to do this but this is what I need to do.

1) Find & replace all words with a particular formatting (say italicized) with another format (like underlined)

2) change font color. say if text is blue I need to change it to black.

Something that would search the whole document and do this would be great.

Any advice would be welocome.

Thanks,

Discussion is locked

- Collapse -
I don't think this is the right way ...
Apr 16, 2007 5:49PM PDT

to use Word.

The way Word is designed is to apply a custom style to those parts of the text you want to change the appearance of. To change it, change the contents of the style.

A very crude way to do change #1 now would be to change the document as html, and see what styles Word applies (open the html-file in Notepad). Then change that style, save, reopen in Word and save as document. But you'll lose details of the formatting, I'm afraid.

Hope this helps (for future use).

Kees

- Collapse -
Simple
Apr 22, 2007 8:04PM PDT

To make the change the original poster asked, the simplest thing is to use Word's built-in Find & Replace.
* Use Edit | Replace... to open the dialog.
* Press the More>> button.
* Click in the Find field
* At the very bottom of the dialog, press the Format button.
* Select the Font... option
* Choose the Font formatting you're looking for & press the OK button. You'll see your selection appear in text under the Find field (e.g., "Font color: Blue")
* click on the Replace field.
* Again press the Format button & select, e.g., Font...
* Choose what you want the new formatting to be & press OK. Verify it's correct by what's written under the Replace field. You can use the No Formatting button to clear whatever you've previusly chosen for either field (first click on the relevant field: Find or Replace)
* Note that there is no text in the Find or Replace fields -- you just want to change formatting.
* Use the buttons Find Next, Replace, or Replace All

This approach will handle both your examples. Good luck.