RegExp Find & Replace 4.3 w/ 253 presets (2011-07-06) [MM2+]

Download and get help for different MediaMonkey Addons.

Moderators: Peke, Gurus

Kevinowpb
Posts: 126
Joined: Sat Dec 22, 2007 10:18 am
Location: West Palm Beach
Contact:

Re: RegExp Find & Replace 4.3 w/ 253 presets (2011-07-06) [M

Post by Kevinowpb » Sun Feb 24, 2013 10:02 am

Something in my Maintain Database locked up,... and now I have a bunch of GENRES with ++@$$ O+++++&&&//// ..... What I'll refer as ... "foreign characters.."

How can I do a "Find any file where GENRE contains "foreign characters.. ie non-alpha ...." and clear the entire GENRE field out?

linn
Posts: 170
Joined: Wed Sep 06, 2006 3:59 am

Re: RegExp Find & Replace 4.3 w/ 253 presets (2011-07-06) [M

Post by linn » Tue Feb 26, 2013 11:18 am

@ ZvezdanD
This utility is a wonderful tool,but it would be so much userfriendly if it would be simpler to find a preset.
The presets have numbers ,if these numbers would be shown in the dialog , the presets would be easier to find.
I copied the list to Onenote, i can search the page with a phrase.
but how do i find "Replace acute and grave accents with apostrophes in <Into Field>..." , now if i could use the number........

Image

I am not sure why the numbers ,they are not used ( except that they are shown) as far as i can see.
Image

ZvezdanD
Posts: 3094
Joined: Thu Jun 08, 2006 7:40 pm

Re: RegExp Find & Replace 4.3 w/ 253 presets (2011-07-06) [M

Post by ZvezdanD » Tue Feb 26, 2013 1:55 pm

linn wrote:it would be so much userfriendly if it would be simpler to find a preset.
Yes, I am aware that this script is not very user-friendly when it comes to finding presets. I am already working on a possibility to make grouping of presets easier, but it would help only to find presets in the menu, but not in the F&R dialog box. I am not sure how could I modify that dialog box to make it simpler. I don't think that navigation using preset's number would be any more user-friendly than it is now.

I could give you just few suggestions, some of them are trivial and you may already know about that:
- remove all presets that you don't use, the shorter list is easier to navigate and you could always import some missing preset if you need it from the RegExpReplace.ini file in the Script folder;

- move all favorite presets to the begin of the list;

- group presets by similarity, e.g. put all "track number" presets one after another;

- if you already know the name of the preset you are looking for, maybe it would be easier for you to find it if you sort the list alphabetically: open the RegExp Presets Export/Import dialog box and click on the table header to do that, but keep in mind that this operation is irreversible, so it is recommended that you previously export all your presets to some .ini file;

- navigate through the Preset dropdown list using the Up/Down keys on the keyboard, maybe it would be faster for you than using the mouse and scroll bar;

- if you just want to edit some existing preset, finding of it would be much easier in the table of the RegExp Presets Export/Import dialog box than it is in the dropdown list in the RegExp Find & Replace dialog box - just click on its number in the table and you would get the similar dialog box as the RegExp Find & Replace for manipulation of presets.

By the way, gggirlgeek already made one custom RegExpReplace.ini file with modified names of presets with added serial numbers in the front which could help navigation by numbers (http://www.mediamonkey.com/forum/viewto ... 19#p333519). Unfortunately, the link to that file is not working anymore, so you could try to send her a PM asking for it.

Of course, you could make such modifications all by yourself. Here is the short description how to do that much faster than editing the preset names in the F&R dialog box one by one. Firstly, you should install some text editor with good RegEx engine. This example is with EditPad freeware version which has such possibility:
- open RegExpReplace.ini file;
- choose Search|Show Search Panel;
- turn on Regular Expression;
- type "Preset(\d+)=Name: "" in the Search field (without double quotes on the ends);
- type "Preset$1=Name: "$1) " in the Replace field (again, without double quotes on the ends);
- choose Search|Replace All (Ctrl+Alt+F3);
- save file.
Magic Nodes 4.3.3 / 5.2 RegExp Find & Replace 4.4.9 / 5.2  Invert Selection/Select None 1.5.1  Export/Create Playlists for Child Nodes 4.1.1 / 5.4  Expand Child Nodes/Expand All 1.1.2  Event Logger 2.7  Filtered Statistics Report 1.6  Track Redirection & Synchronization 3.4.2  Restore/Synchronize Database 3.1.8 / 4.0.1  Find Currently Playing Track 1.3.2  Queue List 1.2.1  Add to Library on Play 1.0.1  Tree Report for Child Nodes 1.1.1  Update Location of Files in Database 1.4.5 / 2.3  Inherit Child Playlists 1.0.2  Add Currently Playing/Selected Track(s) to Playlist 1.1.2

linn
Posts: 170
Joined: Wed Sep 06, 2006 3:59 am

Re: RegExp Find & Replace 4.3 w/ 253 presets (2011-07-06) [M

Post by linn » Tue Feb 26, 2013 4:22 pm

ZvezdanD wrote:
linn wrote:
it would be so much userfriendly if it would be simpler to find a preset.
Yes, I am aware that this script is not very user-friendly when it comes to finding presets. I am already working on a possibility to make grouping of presets easier, but it would help only to find presets in the menu, but not in the F&R dialog box. I am not sure how could I modify that dialog box to make it simpler. I don't think that navigation using preset's number would be any more user-friendly than it is now.
For me ,numbers would be a help; i'll explain: i have all presets copied to Onenote, i do a page search for "moon"( i know this word is in the preset i seek), Onenote finds the word , i open the F&R dialog box, and go to number 4.

Image
I could give you just few suggestions, some of them are trivial and you may already know about that:
No i didn't know most of these suggestions, thank you for providing these ," remove all presets that you don't use," is a good one! should have thought of this myself :oops:
And "sort the list alphabetically" should help too.

zephyr
Posts: 101
Joined: Fri Oct 07, 2011 2:56 pm

Re: RegExp Find & Replace 4.3 w/ 253 presets (2011-07-06) [M

Post by zephyr » Wed Mar 06, 2013 7:00 am

Hi. New to regular expressions. I have lots of tracks with bad artist info. I went to update with info from the title field, where it contains the title and artist.

Example

Title
Editors / All Sparks
Kings of Leon / Molly's Chambers

Can I get the artist from the title? HOW? Many thanks
Grateful noob

listaykx
Posts: 1
Joined: Sat Dec 01, 2012 3:51 pm

Re: RegExp Find & Replace 4.3 w/ 253 presets (2011-07-06) [M

Post by listaykx » Wed Mar 06, 2013 9:25 am

zephyr wrote:Hi. New to regular expressions. I have lots of tracks with bad artist info. I went to update with info from the title field, where it contains the title and artist.

Example

Title
Editors / All Sparks
Kings of Leon / Molly's Chambers

Can I get the artist from the title? HOW? Many thanks
preset 112 from %programfiles(x86)%\mediamonkey\scripts\auto\regexpreplace.ini: "Assign the begin of <From Field> before specified string to <Into Field> (only if exists)...", run it from the toolbar so you get the options dialog box

amar3213
Posts: 11
Joined: Sat Oct 27, 2012 5:58 am

Add a Script in MM helpful for many users

Post by amar3213 » Sun Mar 10, 2013 4:18 am

Currently I am using a add-on named "RegExp Find & Replace". It has around 256 script in which we generally used only one i.e. the first script
"Replace specified string with another one in <Into Field>...".

It would be better if you add this one script into Tools > Scripts menu because most of the time it is very useful & we generally used it. The add-ons itself content 256 script but it would be better if you add this single script from that huge 256 script, so that, it is available to MM users by default with installation in Tools > Scripts menu.

However the add-ons content more useful script but the first one is mostly used so consider it to include in your next version of MM.

There are the list of some other useful script from this add-ons:

Add (<From Field>) to the end of <Into Field> (only if exists)...
Add specified string to the end of <Into Field> (only if not empty)...
Add leading zero to single-digit Track number
Remove leading and trailing spaces from <Into Field>...
Last edited by Lowlander on Sun Mar 10, 2013 5:20 pm, edited 1 time in total.
Reason: Merged with existing post

nzdreamer55
Posts: 45
Joined: Wed Nov 26, 2008 6:47 pm

Need some help with RegExp Find and Replace

Post by nzdreamer55 » Fri Mar 15, 2013 11:13 pm

Hello everyone,

Got a little find and replace problem. I am using the custom 1 field to store Discog.com ID numbers, but for some reason a lot of my music got the decade place into the custom 1 field for songs that I had not found the Discog.com ID number.

So now the custom 1 field is filled with 1970's, 1980's, 1990's, etc for some of my songs. I want to find any of these and replace it with "Unk".

I don't really know how to use the RegExp and have attached a picture of where I am stuck. Could someone help me correct this so I can replace these values?

Thanks
-S

Image
Last edited by Lowlander on Sat Mar 16, 2013 9:36 pm, edited 1 time in total.
Reason: Merged with existing post

seed_or_die
Posts: 38
Joined: Wed Sep 19, 2012 7:37 am

Re: Need some help with RegExp Find and Replace

Post by seed_or_die » Sat Mar 16, 2013 6:39 pm

you see there it says "replace with" under the [....'s] text you have highlighted. add what you want in that.

nzdreamer55
Posts: 45
Joined: Wed Nov 26, 2008 6:47 pm

Re: Need some help with RegExp Find and Replace

Post by nzdreamer55 » Sat Mar 16, 2013 8:18 pm

Thanks for the idea, but it seems that it just add what I put in the replace with on to what is already in the custom 1 field

I typed in "Unk" because I wanted this to be replaced into where it says 2000s. What am I doing wrong?

Image

seed_or_die
Posts: 38
Joined: Wed Sep 19, 2012 7:37 am

Re: RegExp Find & Replace 4.3 w/ 253 presets (2011-07-06) [M

Post by seed_or_die » Sun Mar 17, 2013 12:40 am

selecct the "Full" button. i dont know what it does, but seems to get the desired outcome.

Image

Kevinowpb
Posts: 126
Joined: Sat Dec 22, 2007 10:18 am
Location: West Palm Beach
Contact:

Re: RegExp Find & Replace 4.3 w/ 253 presets (2011-07-06) [M

Post by Kevinowpb » Sat Mar 23, 2013 1:06 pm

no response/ideas on this one?-->>

Kevinowpb wrote:Something in my Maintain Database locked up,... and now I have a bunch of GENRES with ++@$$ O+++++&&&//// ..... What I'll refer as ... "foreign characters.."

How can I do a "Find any file where GENRE contains "foreign characters.. ie non-alpha ...." and clear the entire GENRE field out?

yarguy
Posts: 296
Joined: Mon Apr 09, 2012 8:34 am

Re: RegExp Find & Replace 4.3 w/ 253 presets (2011-07-06) [M

Post by yarguy » Fri Apr 05, 2013 7:05 am

Regretably I only know a little about using regular expressions, but have been learning. My current issue is how to deal with variable, but fixed length content. Here's the specific example. I have a long list of Schubert Lieder (prolific hardly describes his output) where the titles are currently of the form:

D.108 Der Abend ("Purpur malt die Tannenhügel")

(The D is the Deutsch number after the man who catalogued all Schubert's Compositions.)

In one set of lieder the D number is always 5 characters long with a period after D, as above. I want to move this to the end so that the title would read:

Der Abend ("Purpur malt die Tannenhügel"), D 108

In some others there is no period after the D and so the number is 4 characters long:

D548 Orest auf Tauris (Mayrhofer)

which should be:

Orest auf Tauris (Mayrhofer), D 548

I assume the solution is similar in both cases. Is anyone willing to offer a quick lesson in this?

rovingcowboy
Posts: 14153
Joined: Sat Oct 25, 2003 7:57 am
Location: (Texas)
Contact:

Re: RegExp Find & Replace 4.3 w/ 253 presets (2011-07-06) [M

Post by rovingcowboy » Fri Apr 05, 2013 7:34 am

Kevinowpb wrote:no response/ideas on this one?-->>

Kevinowpb wrote:Something in my Maintain Database locked up,... and now I have a bunch of GENRES with ++@$$ O+++++&&&//// ..... What I'll refer as ... "foreign characters.."

How can I do a "Find any file where GENRE contains "foreign characters.. ie non-alpha ...." and clear the entire GENRE field out?
Only thing i can think of is to go through your collection one genere at a time, and add then number 1 to the end of every genere in the songs properties panel, you can do that in groups of songs by adding genere column in the library view screen and sorting the list by genere, and double click the genere text box in the column for one of the songs to open the edit box add the number to the end of the genere name by completely retyping the name and click ok if asked that. Then select that genere you just changed copy it and select all the songs in that genere you are changing by clicking on the genere tag in that same column and holding the shift key while you scroll to see all the songs of that same genere and then right click in the last songs genere column and pasteing the new genere name & number in them. Do that for every genere in your library then you will have all new ones listed in the drop down menu, you then can open the properties of one song and that should let you use the genere drop down menu to delete all the grayed out ones,

Then go back and remove the number from them and repeat the deleteing from the dropdown menu to get rid of the generes with the numbers which would be all grayed out, it will give you an list of new generes and should clear out the ones with the bad characters,


Only other way is find a way to edit the mm database from within the database.
Last edited by rovingcowboy on Fri Apr 05, 2013 7:50 am, edited 1 time in total.
roving cowboy / keith hall. My skins http://www.mediamonkey.com/forum/viewto ... =9&t=16724 for some help check on Monkey's helpful messages at http://www.mediamonkey.com/forum/viewto ... 4008#44008 MY SYSTEMS.1.Jukebox WinXp pro sp 3 version 3.5 gigabyte mb. 281 GHz amd athlon x2 240 built by me.) 2.WinXP pro sp3, vers 2.5.5 and vers 3.5 backup storage, shuttle 32a mb,734 MHz amd athlon put together by me.) 3.Dell demension, winxp pro sp3, mm3.5 spare jukebox.) 4.WinXp pro sp3, vers 3.5, dad's computer bought from computer store. )5. Samsung Galaxy 5 Android 5) 6. Proscan tablet Android 4.3 ) 7. amd a8-5600 apu 3.60ghz mm version 4 windows 7 pro bought from computer store.

rovingcowboy
Posts: 14153
Joined: Sat Oct 25, 2003 7:57 am
Location: (Texas)
Contact:

Re: RegExp Find & Replace 4.3 w/ 253 presets (2011-07-06) [M

Post by rovingcowboy » Fri Apr 05, 2013 7:50 am

yarguy wrote:Regretably I only know a little about using regular expressions, but have been learning. My current issue is how to deal with variable, but fixed length content. Here's the specific example. I have a long list of Schubert Lieder (prolific hardly describes his output) where the titles are currently of the form:

D.108 Der Abend ("Purpur malt die Tannenhügel")

(The D is the Deutsch number after the man who catalogued all Schubert's Compositions.)

In one set of lieder the D number is always 5 characters long with a period after D, as above. I want to move this to the end so that the title would read:

Der Abend ("Purpur malt die Tannenhügel"), D 108

In some others there is no period after the D and so the number is 4 characters long:

D548 Orest auf Tauris (Mayrhofer)

which should be:

Orest auf Tauris (Mayrhofer), D 548

I assume the solution is similar in both cases. Is anyone willing to offer a quick lesson in this?

Sorry i dont know your answer.
roving cowboy / keith hall. My skins http://www.mediamonkey.com/forum/viewto ... =9&t=16724 for some help check on Monkey's helpful messages at http://www.mediamonkey.com/forum/viewto ... 4008#44008 MY SYSTEMS.1.Jukebox WinXp pro sp 3 version 3.5 gigabyte mb. 281 GHz amd athlon x2 240 built by me.) 2.WinXP pro sp3, vers 2.5.5 and vers 3.5 backup storage, shuttle 32a mb,734 MHz amd athlon put together by me.) 3.Dell demension, winxp pro sp3, mm3.5 spare jukebox.) 4.WinXp pro sp3, vers 3.5, dad's computer bought from computer store. )5. Samsung Galaxy 5 Android 5) 6. Proscan tablet Android 4.3 ) 7. amd a8-5600 apu 3.60ghz mm version 4 windows 7 pro bought from computer store.

Post Reply