View Single Post
Old 08-06-2010, 06:48 PM   #6
jackie_w
Wizard
jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.
 
Posts: 2,736
Karma: 3973167
Join Date: Sep 2009
Location: UK
Device: Sony PRS-350, PB360, Kobo Glo/AuraHD/Aura6"
Quote:
Originally Posted by mark235 View Post
I found that using wildcards in "find and replace" in Word can help here:

find: (*)^13(\(\1\))
replace: \1
The options for using wildcards and using bold text in the replace field also need to be activated. However, the problem with this search and replace solution is that Word freezes when it's applied to documents longer than 5 pages! Is there another way to get rid of the 2nd header in brackets and bold the first one?
The first part of your Find: string is very general. It would match every line. Does Word behave any better if you make it more specific? e.g.

find: (Chapter [0-9]{1,3})^13(\(\1\))
replace: \1

which would get less hits.

Also, as an aside, you may find it more useful to have your Replace specify formating of Style "Heading 2" (or any other of the built-in Heading styles) rather than Bold. If you do this, when you use Calibre to convert to mobi you will be able to use the Heading 2 tags to specify a TOC. If you don't like the way Heading 2 looks in Word then modify the built-in Style first.
jackie_w is offline   Reply With Quote