Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Finding and converting text in Word

Status
Not open for further replies.

utoyo

Technical User
Mar 5, 2005
123
US
I'm wondering how I would go about taking underlined text and removing the underlining and taking strike through text and removing the text all together. I'd also like to change an indicator which is a list field in word.

I realize this is probably pretty simple, but if someone could point in the right direction that would be much appreciated.

Thanks in advance.

 
Hi utoyo,

You can do this without vba, using Find/Replace.

For the underlining, use:
'^?' with underline formatting selected in the 'Find what' box
'^&' with no underline formatting selected in the 'Replace with' box.

For the strikethrough, use:
'^?' with strikethrough formatting selected in the 'Find what' box
nothing in the 'Replace with' box.

You can use the macro recorder to record these actions for future automation. In this case, the returned code is almost as efficient as what one might write by hand.

Cheers


[MS MVP - Word]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top