I'm using the Find and Replace feature in a large word document I have. I need to find the word REMARKS: (all bold and upppercase).
REMARKS: THIS IS SOME IMPORTANT DATA
At then end of that line or after a line break is a TABLE if that can help in the reqex.
Using find / replace with use Wildcards Checked and this expression:
<(REMARKS:*[A-Z])
I've found the word and the first Char after the space:
REMARKS: T
What can I add to make it stop at the end of the line? There is always a table the proceeds this "REMARK:" text
For example in javascript: /.REMARKS:\s([A-Z,0-9]).+/g will find it, but is not acceptable in Word's find and replace....
I've also found that using:
<(REMARKS:[A-Z]^l) or <(REMARKS:[A-Z]^13) will get me closer.
1 Answer
Match string AFTER known word to End of Line
Use the following regular expression:
<(REMARKS:[0-9A-Z ]@[^13^|])Notes:
<matches "The beginning of a word"[0-9A-Z ]matches any number, uppercase letter, or space@matches "One or more occurrences of the previous character or expression"[^13^|]matches a paragraph marker or a manual line break.