XML Elements delete

Get help with installation and running here.

Moderators: DataMystic Support, Moderators

mhaegele
Posts: 1
Joined: Mon May 13, 2013 10:06 pm

XML Elements delete

Postby mhaegele » Mon May 13, 2013 10:11 pm

Hello,
I have this XML-file

<Annotation about="www.medinfo.de/*" timestamp="0x0004ac47f7fc01cc" href="ChB3d3cubWVkaW5mby5kZS8qEMyD8L__iKsC">
<Label name="_12345" />
<AdditionalData attribute="original_url" value="www.medinfo.de" />
</Annotation>
<Annotation about="www.brustkrebs-info.de/*" timestamp="0x0004abb3c0c8ce1c" href="Chh3d3cuYnJ1c3RrcmVicy1pbmZvLmRlLyoQnJyjhrz2qgI">
<Label name="_543" />
<AdditionalData attribute="original_url" value="www.brustkrebs-info.de" />
</Annotation>
<Annotation about="www.iqtg.de/*" score="1" timestamp="0x0004ab1636200d27" href="Cg13d3cuaXF0Zy5kZS8qEKeagLHj4qoC">
<Label name="_12345" />
<AdditionalData attribute="original_url" value="www.iqtg.de" />
</Annotation>

and I need to delete all XML-Elements with the <label Name="_543" />

Is there a chance to do this with Textpipe?

The result should be
<Annotation about="www.medinfo.de/*" timestamp="0x0004ac47f7fc01cc" href="ChB3d3cubWVkaW5mby5kZS8qEMyD8L__iKsC">
<Label name="_12345" />
<AdditionalData attribute="original_url" value="www.medinfo.de" />
</Annotation>
<Annotation about="www.iqtg.de/*" score="1" timestamp="0x0004ab1636200d27" href="Cg13d3cuaXF0Zy5kZS8qEKeagLHj4qoC">
<Label name="_12345" />
<AdditionalData attribute="original_url" value="www.iqtg.de" />
</Annotation>



Thank your for your hint.

Sincerely
Michael

User avatar
DataMystic Support
Site Admin
Posts: 2138
Joined: Mon Jun 30, 2003 12:32 pm
Location: Melbourne, Australia
Contact:

Re: XML Elements delete

Postby DataMystic Support » Tue May 14, 2013 8:49 am

Isn't this just a search/replace of

Code: Select all

<label Name="_543" />


replace with nothing?

Use an Exact search/replace, and you may want to add an extra cr/lf after the text above to remove the extra line feed.
Regards,

Simon Carter, http://DataMystic.com/forums/index.php
http://PredictBGL.com - Insulin dose calculator for Type 1 diabetes
http://DownloadPipe.com - 250,000 free software downloads
http://DetachPipe.com - send huge email attachments


Return to “TextPipe Tips and Tricks, Questions and Support”

Who is online

Users browsing this forum: No registered users and 3 guests