What is wrong with this wildcard search?

P

Paul B

I've got a doc with several instances like this one:

LECTURE IX
CONVERSION

I'm trying to change that to:

Lecture IX: CONVERSION

This search string, with wildcards enabled,

LECTURE ([A-Z]{1,5})

does select the first line, above. But if I add a capture:

LECTURE ([A-Z]{1,5})\1

I get no hits. I can't see what I've done wrong here.

Thanks,
p.
 
T

Tony Jollans

I think you're trying to do what Word already does for you. The
parenthesised expression is 'captured' automatically and "\1" can be used to
position it in the replace string without you needing to do anything. Adding
to the Find string means Word is looking for "\1" after your string, and
can't find it.
 
P

Paul B

I think you're trying to do what Word already does for you. The
parenthesised expression is 'captured' automatically and "\1" can be used to
position it in the replace string without you needing to do anything. Adding
to the Find string means Word is looking for "\1" after your string, and
can't find it.

Tony, did I ever tell you you're absolutely brilliant? <g>

Thanks,
p.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top