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

Post a reply

Smilies
:D :) :( :o :-? 8) :lol: :x :P :oops: :cry: :evil: :roll: :wink:

BBCode is ON
[img] is ON
[flash] is OFF
[url] is ON
Smilies are ON

Topic review
   

Expand view Topic review: RegExp Find & Replace 4.3 w/ 253 presets (2011-07-06) [MM2+]

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

by carkey151 » Tue Aug 04, 2020 9:47 am

Thank you, Problem solved

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

by martialartsguy » Tue Aug 04, 2020 9:29 am

carkey151 wrote: Tue Aug 04, 2020 9:12 am Could you please show me what the original Preset 4 (Remove specified string from <Into Field) is supposed to be in the Mediamonkey.ini? I somehow screwed this up and have no "Source Field", only the "Destination Field" or can I fix this in another way?
Here's a screenshot of the fields in the script itself:
https://imgur.com/EvjRke1

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

by carkey151 » Tue Aug 04, 2020 9:12 am

Could you please show me what the original Preset 4 (Remove specified string from <Into Field) is supposed to be in the Mediamonkey.ini? I somehow screwed this up and have no "Source Field", only the "Destination Field" or can I fix this in another way?

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

by ZvezdanD » Fri Jul 24, 2020 11:39 am

There is a problem with some fields used with presets that change both fields, source and destination, i.e. Into and From. Here is the list of those fields:
- Date [MM3+]
- Original Date [MM3+]
- Folder
- Filename
- Extension
- Playback %
- Type [MM4]

Those are complex fields that are not represented by SongData MM interface, but they are based on the existing ones. The Date is based on Year, Month and Day; The Folder, Filename and Extension are based on Path, and so on.

Those fields could be used with presets that change only destination (Into) field. I will look at this problem, but I doubt I could do anything about it.

If you have only year part of that field used, you could try to swap Year with Original Year.

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

by SugarRush » Fri Jul 24, 2020 10:13 am

hi,
i have a problem with preset "Swap <From Field> and <Into Field>..."

i want to exchange Date <>Original Date.

when trying i get "there is a problem replacing "original date field" for the file xxx
Result: Expression error!


latest MMW, windows 10, latest (paid) 5.2.0.241 version ofr RegExp Find Replace

any ideas?

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

by TLD » Tue Jul 07, 2020 7:30 pm

Hello, All,

I tried to find this answer a variety of ways - It's either not present or written in such a way as to not find it...

I've got a bunch of media files from various sources that have been moved from drive to drive over a long time... Because of the method used each time, some of the filenames have "repeating text"
The tags on these are not correct or I'd just use that data... I've yet to take time to go through and fix the tags. However, I'd like to shorten the filenames by removing the "duplicate" text.

For example:
Q:\folder\001-005 - Can't Buy Me Love - Beatles, The --01- 005)Can't Buy Me Love - The Beatles [603] [131] Track - Beatles, The [329]) Track10 - Beatles, T [683]) Track10 - Beatles, T [404]).mp3

I want that to be:
Q:\folder\001-005 - Can't Buy Me Love - Beatles, The --[603] [131] Track - Beatles, The [329]) Track10 - Beatles, T [683]) Track10 - Beatles, T [404]).mp3

Second and etc. pass would find those extra "Beatles, The" and "Beatles, T", etc.
Q:\folder\001-005 - Can't Buy Me Love - Beatles, The --[603] [131] Track - [329]) Track10 - Beatles, T [683]) Track10 - Beatles, T [404]).mp3
Q:\folder\001-005 - Can't Buy Me Love - Beatles, The --[603] [131] Track - [329]) Track10 - [683]) Track10 - [404]).mp3
Q:\folder\001-005 - Can't Buy Me Love - Beatles, The --[603] [131] Track - [329]) 10 - [683]) 10 - [404]).mp3
Q:\folder\001-005 - Can't Buy Me Love - Beatles, The --[603] [131] Track - [329]) 10 - [683]) [404]).mp3
etc. (Shorter - some filenames by a lot!)

Any idea whether RegExp Find & Replace is capable of doing this? I tried writing some regex to search/replace on a few sites, and found an expression that seemed to work right...
Search: ((q:\\)(.*?)(.{3,}))(.*?)\4(.*)
Repalce: \2\3\4\6
(Q is the drive they're on, tests on full filenames worked.)

Has anyone ever written such a search? The big problem is the text being replaced is different for each file, different length, etc. (I can get rid of the extra whitespace at any time - left in for illustration.) The above makes no difference at all - no matches.

Thank you,

-- TLD

***For others searching for this:
Regex duplicate text remove
Repeating text field
Shorten filename extra text

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

by ZvezdanD » Tue May 19, 2020 1:46 pm

jetkins wrote: Mon May 18, 2020 7:20 pmwhen I try to run the "Reset Last Played field" on one of these files, I get an "Expression Error!" failure.
Please post the screenshot of the Preset Settings dialog box with selected the mentioned preset and the file that has that error.

By the way, the "Clear <Into Field>..." preset is only for textual fields.

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

by jetkins » Mon May 18, 2020 7:20 pm

Hi, folks. New MM user here, and I was referred to this addon when I asked how I could reset the Last Played date on a couple of hundred of my files which appear to have invalid data in that field. I've downloaded and installed, but when I try to run the "Reset Last Played field" on one of these files, I get an "Expression Error!" failure. I also get the same if I run the "Clear <Into Field>..." preset and select Last Played as the target.

Unfortunately the error message doesn't provide any further information. Is there a log or diagnostic option that I can set to try to get a handle on why it's barfing on these files?

Thanks!

Batch add artist name before the album title with RegExpReplace

by jz1276 » Fri Dec 20, 2019 4:56 am

Hello. Recently wiped out my PC & can't remember how I had MM set up to to batch add artist name before the album title (The Beatles: Abbey Road"). I have the "RegExpReplace-4.4.4.mmip" file, but cannot remember what to do. Please help, thanks!

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

by jz1276 » Sun Nov 17, 2019 1:12 pm

Recently formatted my computer & can't remember how I created a custom preset for this. All I'm looking to do is to add the artist name before the album title. Any help's appreciated!

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

by Polystyrene » Sat Nov 02, 2019 5:41 pm

Polystyrene wrote: Sat Nov 02, 2019 2:33 pm This add-on is very powerful and I use it quite often to move information from one field to an other (like feat. artist).
I would have been great to add the capability to move information in one step, with presets I have to use copy first and remove in a second step.
I have just installed the new version and I realize that it's a already feature of the registered version... great job !

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

by Polystyrene » Sat Nov 02, 2019 2:33 pm

This add-on is very powerful and I use it quite often to move information from one field to an other (like feat. artist).
I would have been great to add the capability to move information in one step, with presets I have to use copy first and remove in a second step.

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

by ZvezdanD » Mon Oct 14, 2019 6:41 am

lomah wrote: Mon Oct 14, 2019 6:11 amI was just wondering if anyone else was using your add-on along with F-Secure and had noticed the same file blocking.
It's all right, I am not offended, although I don't like if someone is suspicious about my behavior. I am the one who don't like malicious software either and I think the world would be much better place without it. I don't like having installed firewall and anti-virus software who slows down my computer and takes 1GB on its hard disk just to be safe of those rotten apples.

Yes, there was reports about F-Secure in this thread, just use the search tool of the forum and you will find them.

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

by lomah » Mon Oct 14, 2019 6:11 am

ZvezdanD wrote: Sat Oct 12, 2019 10:34 am
lomah wrote: Sat Oct 12, 2019 2:32 amCan I just have some assurance that it's absolutely safe?
I don't know what kind of assurance you expect from me. I am here for more than 10 years, with more than 3000 posts, and almost 20 add-ons. For all those years nobody complained about the safety of my add-ons, excluding those reports about F-Secure that I have mentioned in the Notice section of the add-on's web page.

Besides, my add-ons could be reviewed for malicious code by anyone who knows VBScript.
Hi,
My post was not intended to offend you, as the author of the add-on, so I apologise if it did. As I said in my original post I think the add-on is excellent. I was just wondering if anyone else was using your add-on along with F-Secure and had noticed the same file blocking. That's all. I will whitelist your add-on in F-Secure. Have a good day.

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

by ZvezdanD » Sat Oct 12, 2019 10:34 am

lomah wrote: Sat Oct 12, 2019 2:32 amCan I just have some assurance that it's absolutely safe?
I don't know what kind of assurance you expect from me. I am here for more than 10 years, with more than 3000 posts, and almost 20 add-ons. For all those years nobody complained about the safety of my add-ons, excluding those reports about F-Secure that I have mentioned in the Notice section of the add-on's web page.

Besides, my add-ons could be reviewed for malicious code by anyone who knows VBScript.

Top