Yeah, there is a problem with a label control and ampersand. Anyway, in the next version of the script label control will be replaced and this bug resolved.Davo wrote:I just noticed when i selected a Title field that in the "before" & "after" area it displays ampersands as underscores.
RegExp Find & Replace 4.3 w/ 253 presets (2011-07-06) [MM2+]
-
- Posts: 374
- Joined: Sat Feb 02, 2008 1:09 pm
- Location: Texas
Thanks!
Many, many thanks, for the script and the helpful & detailed description of its functions, ZvezdanD!!
For sure, that will prove as an extremely useful script for many and came just at the right time for me , as I am just starting to give some more order to a rather large collection. (At the moment I am working on giving uniform titles for different interpretations of the same pieces of (mostly classical) music and your script already saved me hours of editing track by track.)
If I may add a question to my laudatio:
Is there an expression that allows to increase a numerical value inside a string over several selected items? Somewhat similar to the "Auto-increment Track #s" script?
Best wishes!
fritz
P.S.: It may sound somewhat pathetic, but for me it's a wonder and source of great happiness what the commitment and ingenuity of the MM-developers and all the capable community members accomplish here... .
For sure, that will prove as an extremely useful script for many and came just at the right time for me , as I am just starting to give some more order to a rather large collection. (At the moment I am working on giving uniform titles for different interpretations of the same pieces of (mostly classical) music and your script already saved me hours of editing track by track.)
If I may add a question to my laudatio:
Is there an expression that allows to increase a numerical value inside a string over several selected items? Somewhat similar to the "Auto-increment Track #s" script?
Best wishes!
fritz
P.S.: It may sound somewhat pathetic, but for me it's a wonder and source of great happiness what the commitment and ingenuity of the MM-developers and all the capable community members accomplish here... .
Re: Thanks!
Sorry, regular expressions are mainly used to find and replace parts of string, but not for such complex transformations as you wish. Some of RegExp implementations (Perl,...) have a support for case changing functions, something like Upper and Lower in SQLite. Unfortunately, in VB scripts even those RegExp functions are not supported. I have a plan to implement them for the next version of this script, but I couldn't give any promise about that.Friedrich wrote:Is there an expression that allows to increase a numerical value inside a string over several selected items? Somewhat similar to the "Auto-increment Track #s" script?
However, maybe you could do this what you want in several iterations, but I am not sure because I don't know exactly what is your intention. For example, if you want to change just one number with only one digit, you could write something like this:
Find what: (\D)7\b
use RegExp1: Yes
Replace with: $18
This will replace all "7" which is not preceded by some digit to "8". So, with this you could replace CD7 to CD8, but not CD7x to CD8x nor CD17 to CD18. For other numbers ("1" to "2", "2" to "3",....) you should modify this example. There are also other similar possibilities, but you should be more specific.
Glad you like all of this what we do. Maybe you should post this message as a new thread, so other scripters who are not visiting this thread could see your opinion about their works.for me it's a wonder and source of great happiness what the commitment and ingenuity of the MM-developers and all the capable community members accomplish here... .

What I meant was the following:
Lets say I have 5 tracks from the Suite No. 1 in D minor, BWV 812 with titles as follows:
Allemande
Courante
Sarabande
Menuet I/II
Gigue
I like them to have the following form instead:
Suite No. 1 in D minor, BWV 812, 1. Allemande
Suite No. 1 in D minor, BWV 812, 2. Courante
Suite No. 1 in D minor, BWV 812, 3. Sarabande
Suite No. 1 in D minor, BWV 812, 4. Menuet I/II
Suite No. 1 in D minor, BWV 812, 5. Gigue
So for the most important part of the job your script comes in very handily (always missed a function like that...):
Adding the string "Suite No. 1 in D minor, BWV 812, " into the title!
Adding increasing numbers (from 1. to 5.) is obviously not what regular expressions, -thanks again for your kind explanation...-, are made for and require a kind of algorithm like the one in the "AutoIncTrackN.vbs":
Even if it were possible to realize somehow it would probably be a waste of time to try to provide such a rarely needed function.
I will live happily without it...
Best regards!
fritz
Lets say I have 5 tracks from the Suite No. 1 in D minor, BWV 812 with titles as follows:
Allemande
Courante
Sarabande
Menuet I/II
Gigue
I like them to have the following form instead:
Suite No. 1 in D minor, BWV 812, 1. Allemande
Suite No. 1 in D minor, BWV 812, 2. Courante
Suite No. 1 in D minor, BWV 812, 3. Sarabande
Suite No. 1 in D minor, BWV 812, 4. Menuet I/II
Suite No. 1 in D minor, BWV 812, 5. Gigue
So for the most important part of the job your script comes in very handily (always missed a function like that...):
Adding the string "Suite No. 1 in D minor, BWV 812, " into the title!
Adding increasing numbers (from 1. to 5.) is obviously not what regular expressions, -thanks again for your kind explanation...-, are made for and require a kind of algorithm like the one in the "AutoIncTrackN.vbs":
Code: Select all
if Form.ShowModal=1 then
number = SE.Value
' Process all selected tracks
For i=0 To list.count-1
Set itm = list.Item(i)
' Swap the fields
itm.TrackOrder = number
number = number + 1
Next
list.UpdateAll
End If
I will live happily without it...

Best regards!
fritz
perhaps its possible to add a custom increment() to allow for such with RegEx.
or perhaps even more simply, allowing the use of the selection # to be applied to the field...
ie
in the dialog it shows selection #/Total Selection (inbetween the > and find next button), if you could select the tracks you want and apply that selection position number to the field for each of the tracks selected.
or perhaps even more simply, allowing the use of the selection # to be applied to the field...
ie
in the dialog it shows selection #/Total Selection (inbetween the > and find next button), if you could select the tracks you want and apply that selection position number to the field for each of the tracks selected.
New script:
Last.FM Node Now with DJ Mode!
Last.fm + MediaMonkey = Scrobbler DJ!
Tag with MusicBrainz ~ Get Album Art!
Tweak the Monkey! ~ My Scripts Page


Last.fm + MediaMonkey = Scrobbler DJ!
Tag with MusicBrainz ~ Get Album Art!
Tweak the Monkey! ~ My Scripts Page

If your track numbers are from 1 to 5 for mentioned tracks, you could do what you want with several steps on same tracks:Friedrich wrote:Lets say I have 5 tracks from the Suite No. 1 in D minor, BWV 812 with titles as follows:
I step:
Find with: ^
in: Title
use RegExp1: Yes
Replace with: .
use RegExp2: No
II step:
Find what: ^
in: Title
use RegExp1: Yes
Replace with: .*
in: Track #
use RegExp2: Yes
III step:
Find what: ^
in: Title
use RegExp1: Yes
Replace with: Suite No. 1 in D minor, BWV 812,
use RegExp2: No
As you can see, if you put only "^" in the Find what text box, this means that you want to insert some text in the front of the find in field. If you are interested to insert some text in the end of the find in field you could put "$" in the Find what text box.
Thanks for your thoughts, Teknojunky.
(In the dialog and of course in the code. "oSongList.Count" when I am guessing correctly; sorry, I am an almost complete coding illiterate)
But I guess it would not be that easy to get it implemented in a handy & easy for all to understand way into the dialog window?
The number (count) of selected tracks would seemingly be the way to go as obviously, -like you pointed out-, the information is already there.Teknojnky wrote:or perhaps even more simply, allowing the use of the selection # to be applied to the field...
ie
in the dialog it shows selection #/Total Selection (inbetween the > and find next button), if you could select the tracks you want and apply that selection position number to the field for each of the tracks selected.
(In the dialog and of course in the code. "oSongList.Count" when I am guessing correctly; sorry, I am an almost complete coding illiterate)
But I guess it would not be that easy to get it implemented in a handy & easy for all to understand way into the dialog window?
Last edited by Friedrich on Wed May 07, 2008 2:45 am, edited 2 times in total.
@ZvezdanD
Thanks for your advice. Thats a nice workaround.
Definitely easier and safer than what I used to do until now.
(Using the auto-organize & Auto-tag from filename function back and forth to get the numbers into the title)
At least for complete albums its easy to change the track numbers temporarily with the Auto-increment script to match the desired number patterns, so that the 3 steps you explained above can be applied to the whole album.
---
2 questions concerning the scripts behaviour:
1. The script-window closes when I choose the "Replace all" button.
2. Am I wrong, or does the script not synchronize the tags?
Is it intended to be like this?
Have a nice day!
fritz
Thanks for your advice. Thats a nice workaround.
Definitely easier and safer than what I used to do until now.
(Using the auto-organize & Auto-tag from filename function back and forth to get the numbers into the title)
At least for complete albums its easy to change the track numbers temporarily with the Auto-increment script to match the desired number patterns, so that the 3 steps you explained above can be applied to the whole album.
---
2 questions concerning the scripts behaviour:
1. The script-window closes when I choose the "Replace all" button.
2. Am I wrong, or does the script not synchronize the tags?
Is it intended to be like this?
Have a nice day!
fritz
I am trying to simplify this for the next version, so that only one step could be used.Friedrich wrote:At least for complete albums its easy to change the track numbers temporarily with the Auto-increment script to match the desired number patterns, so that the 3 steps you explained above can be applied to the whole album.
Yes, this is intended to be like that, but I think I'll change that in the next version.1. The script-window closes when I choose the "Replace all" button.
Sorry, there was a bug (same as in Magic Nodes). Thanks for the report.2. Am I wrong, or does the script not synchronize the tags?
You could take a new release of this script from the first post of this thread.
Great!ZvezdanD wrote:I am trying to simplify this for the next version, so that only one step could be used.
Its a bit unpractical only when doing multiple operations on the same files.Yes, this is intended to be like that, but I think I'll change that in the next version.
You bet i will, ...did.You could take a new release of this script from the first post of this thread.
---
One function, among many others, that I find particularly useful:
Moving the content, -completely or parts of it!-, from one field to any position you can imagine of another field!
@all
To those who at first glance might be frightened a bit by the abstract syntax, like I was:
The more you get used to it, the more you will love it!
Get on and do all the things with your tags, you always wanted to do, but were too lazy to do, because they required a heck of a lot of track-by-track-work....

This is just the type of script I was looking for. However, while attempting to install the script (downloaded today - May 9th), I received an error message: "Product Installation error."
I am using the latest version of MM (3.0.2.1134) Gold and Windows Vista.
I also noticed the script was updated two days ago - might this be an issue or am is something wrong on my end?
I am using the latest version of MM (3.0.2.1134) Gold and Windows Vista.
I also noticed the script was updated two days ago - might this be an issue or am is something wrong on my end?
Advanced Duplicate Find & Fix Find More From Same - Custom Search. | Transfer PlayStat & Copy-Paste Tags/AlbumArt between any tracks.
Tagging Inconsistencies Do you think you have your tags in order? Think again...
Play History & Stats Node Like having your Last-FM account stored locally, but more advanced.
Case & Leading Zero Fixer Works on filenames too!
All My Scripts
Tagging Inconsistencies Do you think you have your tags in order? Think again...
Play History & Stats Node Like having your Last-FM account stored locally, but more advanced.
Case & Leading Zero Fixer Works on filenames too!
All My Scripts