# Help with a regex rule

**URL:** <https://forum.xbench.net/t/help-with-a-regex-rule/746>\
**Category:** Technical Support\
**Created:** [March 1, 2021, 4:00pm UTC](https://forum.xbench.net/t/help-with-a-regex-rule/746 "2021-03-01T16:00:41Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jelena](https://avatars.discourse-cdn.com/v4/letter/j/f19dbf/32.png) [@Jelena](https://forum.xbench.net/u/Jelena)\
**Post date:** [March 1, 2021, 4:00pm UTC](https://forum.xbench.net/t/help-with-a-regex-rule/746/1 "2021-03-01T16:00:41Z")

</div>

Hi,  
I’m trying to create a personal checklist rule where it would detect if in a segment there is an occurrence of “TAGpx” (without a space between the tag and “px”) in source and in target. The tag here is obviously a variable, but I don’t know if it is possible to set up such a rule? Would you be able to help me out? Thank you.

---

<div class="post-metadata">

**Author:** ![omartin](https://yyz1.discourse-cdn.com/flex035/user_avatar/forum.xbench.net/omartin/32/82_2.png) [@omartin](https://forum.xbench.net/u/omartin)\
**Post date:** [March 2, 2021, 7:57am UTC](https://forum.xbench.net/t/help-with-a-regex-rule/746/2 "2021-03-02T07:57:35Z")

</div>

Hi,

I would use the following search to detect those segments:

Source: `"[^[:space:]]px>"`  
Target: `"[^[:space:]]px>"`

Search mode: Regular Expressions  
PowerSearch: On.

If you want to detect only in Source or only in Target, create a checklist entry with the source or target search.

If you specify a variable sample, we could improve the search.

---

<div class="post-metadata">

**Author:** ![Jelena](https://avatars.discourse-cdn.com/v4/letter/j/f19dbf/32.png) [@Jelena](https://forum.xbench.net/u/Jelena)\
**Post date:** [March 2, 2021, 9:34am UTC](https://forum.xbench.net/t/help-with-a-regex-rule/746/3 "2021-03-02T09:34:12Z")

</div>

> [@omartin](#):
>
> “[\[1\]]px\>”

Thank you, it works!

* * *

1. :space:
