# Need Help With "Case Conversion"; Scripts

**URL:** https://community.mp3tag.de/t/need-help-with-case-conversion-scripts/13708
**Category:** Support
**Created:** [July 31, 2012, 10:03pm UTC](https://community.mp3tag.de/t/need-help-with-case-conversion-scripts/13708 "2012-07-31T22:03:58Z")
**Posts on this page:** 1
**Showing post:** 2

<div class="post-metadata">

### Author: ![stevehero](https://community.mp3tag.de/user_avatar/community.mp3tag.de/stevehero/32/337_2.png) [@stevehero](https://community.mp3tag.de/u/stevehero)
#### Post date: [August 1, 2012, 1:04am UTC](https://community.mp3tag.de/t/need-help-with-case-conversion-scripts/13708/2 "2012-08-01T01:04:21Z")

</div>

> [@Egg](#):
>
> Basically, I would like to run a "case conversion" which corrects filenames/tags to Mixed Case on slightly over 30k files. I found the stock Action for doing this in Mp3tag, but it has a few unwanted quirks. For instance, the filename "04 - W.A.S.P.mp3" is changed to "04 - W.a.s.p.mp3".

You have a couple of ways to do this and here are a those examples.

Begin Action Group **Clean-Up 1.2 # Case Retain CAPS With Title Case Elsewhere**** Action #1 **_Actiontype 5:_** Format value **_Field \_\_\_\_\_\_:_** \_FILENAME **_Formatstring:_** $caps2**(**%album% **,**' -(["'.-'**)End Action Group**Clean-Up 1.2 # Case Retain CAPS With Title Case Elsewhere** (1 Action)

Basically as you can see at the link below for further learning the **$caps2** doesn't change what is already caps. Which is what you require. The second parameter '**' -(["'.-'**' is optional and specifies additional characters that triggers upper case. In this case they are **-(["'.-**. Before **-** notice there is a whitespace (blank character).

You are going to have to add other actions to the group ([see here](https://community.mp3tag.de/t/967/1)) for other tags like ARTIST etc using the format value method.

OR use **Replace with regular expression** where you can affect \_ALL (all tags including filename)

 

Begin Action Group **\_Script Test#TEST**

 **Action #1** _Actiontype 4:_ **Replace with regular expression** _Field \_\_\_\_\_\_\_\_\_\_\_\_\_\_:_ **\_ALL** _Regular expression \_:_ **(^|\s|\.|\(|\[)([a-z])** _Replace matches with:_ **$1$caps2($2)** [\_] Case sensitive comparison 

End Action Group **\_Script Test#TEST** (1 Action)

 See [this post](http://forums.mp3tag.de/index.php?s=&s...ost&p=65567) for a more detailed explanation of a similar action.

> [@Egg](#):
>
> Basisally, I would like to Since I have no programming knowledge, I have no idea what they actually do, and I'm not even sure I know how to implement them. Can someone point me in the right direction?

 

You don't need any. \*Practice. Further learning here [https://docs.mp3tag.de/scripting](https://docs.mp3tag.de/scripting)

 

> [@Egg](#):
>
> Roman numerals are also affected in a similar manner. I'm sure this has been dealt with in the past.

 

I've seen a few of these actions around but none have been fully reliable on a large collection. So your safest option is to use this. This goes up to the roman numerals for 25. I find this does my job just fine. You could of you wanted to add the big ones like 'L' and 'C' for 50 and 100.

  

Begin Action Group **Clean-Up 1.2 # Case 'I' 'II' 'III' 'IV' 'V'**

 **Action #1** _Actiontype 4:_ **Replace with regular expression** _Field \_\_\_\_\_\_\_\_\_\_\_\_\_\_:_ **\_TAG** _Regular expression \_:_ **\b(i|ii|iii|iv|v|vi|vii|viii|ix|x|xi|xii|xiii|xiv|xv|xvi|xvii|xviii|xix|xx|x**

**xi|xxii|xxiii|xxiv|xxv)\b(?# abbreviations & acronyms)**

 _Replace matches with:_ **$upper($1)** [\_] Case sensitive comparison 

End Action Group **Clean-Up 1.2 # Case 'I' 'II' 'III' 'IV' 'V'** (1 Action)

---

_[View the full topic](https://community.mp3tag.de/t/need-help-with-case-conversion-scripts/13708)._
