Target Text Before After

This Custom Command allows you to target a text value that is contained before or after a given text, or between 2 other text values

If you only specify the text that appears before your target Text you will then get your Target Text and also all the rest of the text that appears after it (if any). If you only specify the text that appears after your Target Text then you will get your Target Text and all the other text that appears before it (if any)

In the template we offer with this command we are capturing the whole content of the table into the Selector DOM Variable, which will contain all the text within that table. See below screenshot

Now let’s say we want to target the specific tax amount. To do so we need to specify which text appears before it, and which text appears after it. In our table and in a sequential order the word “Tax” will appear before (precede) our target value, and the word “Availability” will appear after (follows) our target value. See below screenshot

We can then test this targeting by feeding the Custom Command to an alert command and see if we are able to isolate the tax amount, see below