Clipboard to SetAttr META

Hi !

I have a MP3 file song. I want to copy the Filename of that file (without the Extension)
and put the result in the Metadata 'Title'.

My code have 2 lines:

First line seams Ok:

CLIPBOARD COPYNAMES=nopaths REGEXP "(.+)...." "\1"

For the Second line,
I had tried these 3 lines without success:

SetAttr META ""Title:" & Clipboard PASTE & """		

SetAttr META "Title:{clip}"

SetAttr META ""Title:" & {clip} & """

Any ideas ?

Thanks.

The filename can be passed directly, see Codes for passing filenames.

This works fine for one file. Is more than one file is selected, all files receive the first file's filename:

@nodeselect 
SetAttr META "title:{file|noext}"

This makes sure all files' titles get their individual data:

@nodeselect 
dopusrt /acmd SetAttr {filepath} META "title:{file|noext}"
1 Like

Works perfect !

Thanks a lot. You made my day !