#1 : 09/02-19 15:31 Spiros
Posts: 5
|
Hi is there any way to characterize any word into the parenthesis for example
(Felguk (Extended) Remix) To: (Felguk Extended Remix) I am using the replace command (Extended) Remix) to Extended Remix) but i want to do that with many files so i am trying to find a away to characterize the word after and before the first parenthesis "Felguk" to keep it intact So the command could be ("whatever symbol i should use" (Extended) Remix) To ("whatever symbol i should use" Extended Remix) Thanks in advance. |
#2 : 09/02-19 22:26 L B
Posts: 74
|
Reply to #1:
Use RegEx & Replace method for this. I am assuming you basically want to remove the innermost parentheses. Replace method: Text to be Replaced = (\(.*)\((.*)\)(.*\)) Replace with = \1\2\3 Use Regular Expressions = Ticked. Alternatively, if you always wanna remove parenthesis around the exact word "Extended", then: Text to be Replaced = (.*)\((Extended)\)(.*) Replace With = \1\2\3 |
#3 : 11/02-19 14:11 David Lee
Posts: 1125
|
Reply to #1:
Simplest regular expression is: Replace " \(|\) " with " " Translates as REPLACE <space> + "(" OR ")" + <space> WITH <space> "|" = OR "\" is the "Escape" character, which means that "(" & ")" represent themselves rather than special RegEx grouping characters. |
#4 : 12/02-19 19:14 L B
Posts: 74
|
Reply to #3:
Wouldn't that remove just the leading parenthesis, not the trailing one, after "Extended"?...since there is no space before the trailing one. |
#5 : 12/02-19 19:59 David Lee
Posts: 1125
|
Reply to #4:
I thought that my explanation made it clear. The RegEx " \(|\) " matches EITHER <a space followed by an opening parenthesis> OR <a closing parenthesis followed by a space>. Either of these is then replaced by a single space. Hence "(Felguk (Extended) Remix)" returns "(Felguk Extended Remix)", as required. |
#6 : 15/02-19 02:22 L B
Posts: 74
|
Reply to #5:
Ohhh, there is a space after the closing parenthesis... Apologies, did not notice that. Yeah, that'd work. |