# Reg Ex Help: Use portion of title for movement name

**URL:** <https://community.mp3tag.de/t/reg-ex-help-use-portion-of-title-for-movement-name/47481>\
**Category:** Support\
**Created:** [January 9, 2020, 3:43pm UTC](https://community.mp3tag.de/t/reg-ex-help-use-portion-of-title-for-movement-name/47481 "2020-01-09T15:43:04Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![esumsea](https://community.mp3tag.de/user_avatar/community.mp3tag.de/esumsea/32/7219_2.png) [@esumsea](https://community.mp3tag.de/u/esumsea)\
**Post date:** [January 9, 2020, 3:43pm UTC](https://community.mp3tag.de/t/reg-ex-help-use-portion-of-title-for-movement-name/47481/1 "2020-01-09T15:43:04Z")

</div>

Hello Everyone!

I have tried to figure this out, search this forum and the web but I can't figure it out. I want to use the "Variation 22" portion of my title "Variations and Fugue on a Theme by Handel, op. 24: XXIII. Variation 22" for the movementname.

So: Variations and Fugue on a Theme by Handel, op. 24: XXIII. Variation 22 = Variation 22

I could just use the cut command but since the amount of characters in front of "Variation" changes, it will not work. Also, the amount of words after Variation changes as well, and I would like to use all those characters so going from the right or left will not work. I basically want movement name to include all characters after the word "Variation" including the word "Variation" as well.

So, the same Reg Ex can make "Variations and Fugue on a Theme by Handel, op. 24: XX. Variation 19: Leggiero E Vivace" = "Variation 19: Leggiero E Vivace"

If this can be figured out, I could also use other portions of the title for movementtotal and movementnumber.

I suspect my problem is with the i in $mid(x,i,n). Any help would be greatly appreciated.

Thanks!

I tried using the $mid command but I could not get it to work.

---

<div class="post-metadata">

**Author:** ![Florian](https://community.mp3tag.de/user_avatar/community.mp3tag.de/florian/32/5759_2.png) [@Florian](https://community.mp3tag.de/u/Florian)\
**Post date:** [January 9, 2020, 4:17pm UTC](https://community.mp3tag.de/t/reg-ex-help-use-portion-of-title-for-movement-name/47481/2 "2020-01-09T16:17:03Z")

</div>

You can use an action "Guess values" where you use `%title%` as source pattern and

`%dummy%: %dummy%. %movementname%`

as guessing pattern.

---

<div class="post-metadata">

**Author:** ![esumsea](https://community.mp3tag.de/user_avatar/community.mp3tag.de/esumsea/32/7219_2.png) [@esumsea](https://community.mp3tag.de/u/esumsea)\
**Post date:** [January 10, 2020, 5:15pm UTC](https://community.mp3tag.de/t/reg-ex-help-use-portion-of-title-for-movement-name/47481/3 "2020-01-10T17:15:06Z")

</div>

Thanks for the quick reply. It worked. I can use this to solve a lot of problems! Thanks again!

---

<div class="post-metadata">

**Author:** ![system](https://community.mp3tag.de/uploads/default/original/2X/c/ce7035d426cb755a7916793326d23b465222a407.png) [@system](https://community.mp3tag.de/u/system)\
**Post date:** [February 9, 2020, 5:15pm UTC](https://community.mp3tag.de/t/reg-ex-help-use-portion-of-title-for-movement-name/47481/4 "2020-02-09T17:15:08Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
