Page 1 of 1

How to carry over information in a Find/Replace

Posted: Fri Jul 06, 2018 1:53 am
by obmark3
I have content within a tag that I need to retain in the output text, but don't know the proper syntax. I used to do this easily with FSR but don't have a 64 bit version.

Input text:
<wd.headnote jur.group="sct" year="1963">

Output text:
<wd.headnote jur.group="sct" year="1963"><note.text>

The year is the value that changes throughout the file, so I need it to carry over.

Please advise.

Thanks!

Mark

Re: How to carry over information in a Find/Replace

Posted: Fri Jul 06, 2018 8:11 am
by Radu
Hi Mark,

In the Oxygen Find/Replace dialog check the "Regular Expression" checkbox, search for:

Code: Select all

(<wd.headnote jur.group="sct" year="\d+">)
and replace with:

Code: Select all

$1<note.text>
Or if you want to work XML-aware, in the Oxygen Tools main menu ->"XML Refactoring" dialog there is a "Wrap Element Content" operation.

Regards,
Radu

Re: How to carry over information in a Find/Replace

Posted: Fri Jul 06, 2018 9:44 pm
by obmark3
Much thanks!