INTERACT FORUM
More => Old Versions => Media Center 17 => Topic started by: 666JackTheKnife666 on December 30, 2011, 12:04:12 am
-
most of my tag's for the name field are [track#] - [song name] - [album name]
example : 001 - bozo - bozo the clown Great hits
ok what I would like to do is remove the track number and the album and have my name field with just the song name.
I am kinda at a loss on how to do this in an automated fashion.
thx for any and all help.
-
Try an expression like
ListItem([name],1,-)
-
Try an expression like
ListItem([name],1,-)
thx for the reply, so where do I use that with, the rename,move,copy tool or somthing elce ?
-
First test by using an Expression Column: http://thewelltemperedcomputer.com/SW/Players/MC14/MC_Expression_columns.htm
Select the lines you want to be changed and use the Excel style expression in the Name column
http://thewelltemperedcomputer.com/SW/Players/MC14/MC_Expression_excel.htm
-
If your tags are populated, then you can use those to drive the rename.
Select the tracks, Rename, Move & Copy Files..., deselect the Directory section, and select the Filename section. Enter the template: [Name] as the Rule (Rule > Insert Field > Name). The preview will show what will be the results.
-
If your tags are populated, then you can use those to drive the rename.
The question seems to be how to rename [Name], not how to use it to rename files. Using Regex() would be the more elegant solution, but ListItem() will work fine. Using ' - ' rather than '-' would avoid legitimate hyphens from being interpreted as delimiters. That, of course, assumes the delimiter always includes spaces. Problems with inconsistent values can be found easily by using an expression column to test the function before using it to change the values in [Name]—as suggested by Vincent. If in doubt, use three expression columns—one for each of [Track #], [Name] and [Album]—to ensure those values are being separated as expected.
-
Sorry, I should have been more clear. I meant ONCE the tags are correctly set, THEN use Rename (as the OP was asking how do accomplish the rename).
You can use this expression as a Filename rule inside the Rename dialog:
if(Regex([filename (name)], /#^(\d+) - (.*) - (.*)(\.[^.]+)$#/), [R3], Filename(,0))
This will show you the previews of what will be renamed. File names that don't match the pattern are left alone.
If you find examples that don't work, we may be able to modify the Regex() to work with these, or you can reduce the selected files and work with those that do.