Find/Replace text yet keep the same numbers?

Everything related to our flagship word processor.
Post Reply
User avatar
CrisB
Posts: 115
Joined: 2006-09-25 10:30:11
Location: Gibraltar, Europe
Contact:

Find/Replace text yet keep the same numbers?

Post by CrisB »

Hi,

I sometimes need to Find a string such as "textabc-123-textdef" and Replace it with "textpqr-123-textst".

So I want to replace the initial text string "textabc" with "textpqr" keep the identical number "123" and then also replace the second text string "textdef" with "textst".

Can I keep the number in the middle unchanged with a Replace? How do I do this with Find/Replace PowerFind?

Any and all help in resolving this issue would be much appreciated, many thanks, Cris
Find strategies to improve your effectiveness at http://www.lifestrategies.net

User avatar
phspaelti
Posts: 1088
Joined: 2007-02-07 00:58:12
Location: Japan

Re: Find/Replace text yet keep the same numbers?

Post by phspaelti »

Your find box should look like this:
Find_CrisB.tiff
Find_CrisB.tiff (88.24 KiB) Viewed 3565 times
The Capture(…) is in the Match menu (in the gear menu)
The AnyDigit is in the Wildcard menu.
The 3 Times is in the Repeat menu.

The Captured1 in the replace box is also in the Match menu. That will match what was found.
philip

User avatar
CrisB
Posts: 115
Joined: 2006-09-25 10:30:11
Location: Gibraltar, Europe
Contact:

Re: Find/Replace text yet keep the same numbers?

Post by CrisB »

Thanks, Philip, but I must be blind. Where's the Find_CrisB tiff attachment to view and/or download from your post? Can you download it from your post? If so, it must be a problem to do with Firefox 25.0.1 and Snow Leopard...
Find strategies to improve your effectiveness at http://www.lifestrategies.net

User avatar
phspaelti
Posts: 1088
Joined: 2007-02-07 00:58:12
Location: Japan

Re: Find/Replace text yet keep the same numbers?

Post by phspaelti »

The CrisB.tiff is an image, and it should just be displayed here on the forum. Does it not display for you?
I'll try as jpg.
Find_CrisB.jpg
Find_CrisB.jpg (38.82 KiB) Viewed 3562 times
philip

User avatar
CrisB
Posts: 115
Joined: 2006-09-25 10:30:11
Location: Gibraltar, Europe
Contact:

Re: Find/Replace text yet keep the same numbers?

Post by CrisB »

Thanks, Philip, the Find Replace jpg is showing now.

much appreciate your help,
warm regards
Cris
Find strategies to improve your effectiveness at http://www.lifestrategies.net

Post Reply