search and replace with wildcards

  • Thread starter Thread starter Alexz
  • Start date Start date
A

Alexz

I have a rather large document in which I would like to replace the
formatting of all definitions, which appear between quotation marks.

For instance, "Company", needs to be replaced in bold and italics. I know
how to search and replace to change fonts, but there are at least 60
definitions in this document and it would be nice to automate that process.
 
Type this in the find what box:

[^0147^01486^34]<*>[^0147^01486^34]

Type ^& in the replace with and format replace with using Bold and Italic.
 
I tried the search "*", wildcard checked and replace empty except for the
bold, italics, and this is not working.
 
I have a rather large document in which I would like to replace the
formatting of all definitions, which appear between quotation marks.

For instance, "Company", needs to be replaced in bold and italics. I know
how to search and replace to change fonts, but there are at least 60
definitions in this document and it would be nice to automate that process.

After checking the "Use wildcards" option, enter

["^0147]<*>["^0148]

in the Find What box, and enter

^&

in the Replace With box. While the cursor is still in the Replace With
box, press Ctrl+B and Ctrl+I. Then click the Replace All button.

The Find What code locates any sequence of characters (starting and
ending at word boundaries, which may include multiple sentences or
paragraphs) surrounded by either straight or curly quotes.

The Replace With code replaces the found text with itself, so none of
the characters change. The Ctrl+B and Ctrl+I make the replacement bold
and italic.

See http://www.gmayor.com/replace_using_wildcards.htm for more.
 
Back
Top