Conditional Subpatterns

Get help with installation and running here.

Moderators: DataMystic Support, Moderators

Post Reply
Posts: 1
Joined: Sun Apr 04, 2021 4:51 am

Conditional Subpatterns

Post by othnijavier » Wed May 05, 2021 12:44 pm

Hello everybody

I want to run some filters in a bunch of XML files only if there is some line in the file that does NOT contain a value/string out from a list of a few values.

Is this where I use conditional subpatterns? Can somebody give me examples or a better way to do what I want?

Thank you

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

Re: Conditional Subpatterns

Post by DataMystic Support » Fri Jun 11, 2021 2:29 pm

Hi there,

How large is the XML content? You can use an EasyPattern like this:

Code: Select all

[ 0+ chars,
'value1' or 'value2' or 'value3',
longest 0+ chars ]
And set the replace with to

Code: Select all

You can then add subfilters which trigger only when the match occurs.

Simon Carter, - Insulin dose calculator for Type 1 diabetes - 250,000 free software downloads

Post Reply