#1 : 24/05-25 19:57 Stefano
Posts: 1
|
Hi all, I need help from community :)
I've multiple files like these: Here the name (Europe) (En,Fr,De,Nl).ext here another name (Europe) (Fr,De).ext and another one (ASIA) (Jp,Hk,Ph).ext and I need: Here the name (Europe).ext here another name (Europe).ext and another one (ASIA).ext basically I need to remove (En,Fr,De,Nl) (Fr,De) (Jp,Hk,Ph) that are obviosuly not the same for each file. I was trying something like (*,*) considering that there is always a comma between parenthesis but it doesn't work also using regular expression. Do you have any suggestions on how to do this? Thanks in advance for any help |
#2 : 24/05-25 21:35 Delta Foxtrot
Posts: 487
|
Reply to #1:
Hi Stefano, I'm surprised our resident Italiano expert, Styb, hasn't jumped on this post already... Anyway, I'll take a stab at it, and he'll probably come and show you the right way to do it later. :) First (and you probably already realize this), you can't have two files with the same name (Europe).ext for instance. Easy enough to fix with a collision rule though. Second, using a remove pattern method, it's just: Replace: .*$ [NOTE: There's a SPACE before the period! Without a space before the period it won't work - so put in quotes it looks like " .*$" (leave out the quotes of course)] Use regular expressions: CHECKED Apply to: Name Best, DF |
#3 : 25/05-25 05:07 Styb
Posts: 180
|
Reply to #1:
Good morning, guys! I'm unable to understand the DF's solution, but I've found another way to achieve the desired result using the Replace method and regular expressions. Replace: (.*) (.*) Replace with: \1 See the following picture: https://i.postimg.cc/yYjKBYZy/Img192.png |
#4 : 28/05-25 20:39 Delta Foxtrot
Posts: 487
|
Reply to #3:
Hi Styb, Well, my face is red... I misinterpreted the filenames. Your way is right, of course. Best, DF |
#5 : 29/05-25 18:11 Styb
Posts: 180
|
Reply to #4:
It also happens to the best men. :) |