View Single Post
  #1   Report Post  
Loes Loes is offline
Junior Member
 
Posts: 1
Default find & replace in footnotes

I have two long documents, with many footnotes, that need to be formatted. Both documents present a different problem in the footnotes, which I would like to solve using a regular expression.

1. Punctuation sign (full stop) missing at the end of a footnote.
I use the following regular expression:
find (search all footnotes that do not end with a punctuation sign), use wildcards activated: ([!.\?\!])(^13)(^2)
replace (add full stop at the end of footnotes not ending with a punctuation sign): \1.\2\3
The regular expression finds the footnotes that should be corrected without any problems, but does not do anything when pressing 'replace', nor 'replace all'.

2. Footnotes separated by a white line, i.e. additional hard return.
I use the following regular expression:
find (search all footnotes that are separated from the next one by an additional hard return), use wildcards activated: (^13)(^13)(^2)
replace (remove one of both hard returns): \2\3
The regular expression, again, finds the footnotes that should be corrected without any problems, but does not do anything when pressing 'replace', nor 'replace all'.

I have the impression the paragraph mark is blocking both regular expressions (looks like Word is thinking I am replacing the paragraph mark at the end of the footnote, which is not allowed). Can anyone confirm this idea and offer some help how to solve it?

Thanks in advance!