Printing files used by a playlist
Can someone tell me how to print a list of the files used by an iTunes playlist? Thank you.
Windows, Windows 10
Can someone tell me how to print a list of the files used by an iTunes playlist? Thank you.
Windows, Windows 10
Right-click on this link and download the file to your desktop >>> ExportCSVLocations.vbs
Select the contents of the playlist that you want details for.
Double-click the script to run it and answer any prompts. You'll likely get a security warning too.
It will produce an output file in CSV format and attempt to open that with Excel or whatever application is registered to open CSV files. You can open the file with a text editor like Notepad if you want.
At present the first line is Location to describe what is in the column below, but that might be redundant in this context. After the last exported record there is a blank line and then another noting when the data was exported. I hadn't considered it before but both header and footer could be made optional.
This is a quick dump of the output with some random tracks in my library:
Location
\Gogol Bordello\Gypsy Punks; Underdog World Strike\09 Start Wearing Purple.m4a
\Breaking Benjamin\Phobia\08 Topless.m4a
\Rag'n'Bone Man\Bluestown\04 Tell'em Like It Is.m4a
\David Bowie\Blackstar\02 'Tis A Pity She Was A Whore.m4a
Exported: 08/03/2021 02:14:21
And yes, it is annoying that iTunes doesn't reveal the path clearly within the application. If that is something you really want access to all the time I have other scripts such as KeywordsToDescription that you can use to copy location into an otherwise unused field.
tt2
Right-click on this link and download the file to your desktop >>> ExportCSVLocations.vbs
Select the contents of the playlist that you want details for.
Double-click the script to run it and answer any prompts. You'll likely get a security warning too.
It will produce an output file in CSV format and attempt to open that with Excel or whatever application is registered to open CSV files. You can open the file with a text editor like Notepad if you want.
At present the first line is Location to describe what is in the column below, but that might be redundant in this context. After the last exported record there is a blank line and then another noting when the data was exported. I hadn't considered it before but both header and footer could be made optional.
This is a quick dump of the output with some random tracks in my library:
Location
\Gogol Bordello\Gypsy Punks; Underdog World Strike\09 Start Wearing Purple.m4a
\Breaking Benjamin\Phobia\08 Topless.m4a
\Rag'n'Bone Man\Bluestown\04 Tell'em Like It Is.m4a
\David Bowie\Blackstar\02 'Tis A Pity She Was A Whore.m4a
Exported: 08/03/2021 02:14:21
And yes, it is annoying that iTunes doesn't reveal the path clearly within the application. If that is something you really want access to all the time I have other scripts such as KeywordsToDescription that you can use to copy location into an otherwise unused field.
tt2
cal_rapids Said:
"I don't need the full path, all the files are in the default iTunes Media folder, so I just the path name after that. Thanks for any help you can offer."
-------
Try Terminal:
Open Terminal, and then drag-and-drop the folder's icon in to Terminal - nothing would be transferred - the entire path would be shown.
If you want to see the Folders and Files afterwards, then use this command:
ls
There is no way to get a playlist stored in iTunes to interact with the Windows Command Prompt.
A playlist in iTunes is an ordered list of references to track objects.
Each track object has an associated location property, but these are not directly readable from iTunes.
A particular playlist might contain tracks with the following locations:
<Media Folder>\<Artist 3>\<Album 2>\01 <Song 1>.<Ext>
<Media Folder>\<Artist 8>\<Album 5>\10 <Song 10>.<Ext>
<Media Folder>\<Artist 1>\<Album 4>\07 <Song 7>.<Ext>
etc.
and the OP is after the following information:
<Artist 3>\<Album 2>\01 <Song 1>.<Ext>
<Artist 8>\<Album 5>\10 <Song 10>.<Ext>
<Artist 1>\<Album 4>\07 <Song 7>.<Ext>
etc.
I have provided a mechanism to extract this information. It could be refined if they are interested. Depends a bit on how often they want to be able to generate this type of information and how comfortable they are manipulating data in Excel (or indeed if they have access to it).
tt2
The task is to read selected data from iTunes and get it into a useful form, e.g. text file, spreadsheet, etc. I've provided a tool already that can get the data into a spreadsheet, but there is more data in the output than required. Trimming down to what is needed is relatively easy, but if the OP wants I can refine the data gathering tool for them so they don't have to manipulate the output after the fact. Or they can tweak my script themselves if they're comfortable with vbScript. There are liberal comments within to guide anyone trying to repurpose the scripts. I'm generally happy to make mods on request.
tt2
What exactly is that you want? All of the file paths? I have a script called ExportCSV that can be used to extract selected data to a spreadsheet that might be what you need.
tt2
Thank you so much for your help. It worked perfectly, just what I needed.
cal_rapids Said:
"Printing files used by a playlist: Can someone tell me how to print a list of the files used by an iTunes playlist? Thank you."
-------
Contact Microsoft Support:
They are the developer of the Windows. Ask them how to find such info in your Operating System.
Start Here: Microsoft Contact Us Virtual Agent - Microsoft Support
You can use the script as it is, take the output file and delete all the columns you don't want, then use a function to trim down the location values if you want. You could potentially tweak the script so that it only exports the field of interest, or if you're really keen you could trim location before writing to the output file.
tt2
Terminal is Mac tool. This thread is about iTunes for Windows. The content of interest is a playlist which may be scattered across numerous folders, a listing of a particular folder's content doesn't cover it.
tt2
turingtest2 Said:
"Terminal is Mac tool. This thread is about iTunes for Windows. The content of interest is a playlist which may be scattered across numerous folders, a listing of a particular folder's content doesn't cover it."
-------
To Emphasize:
May have misread "the path name after that". The reply seemed as though the OP was clarifying that they wanted to locate a Folder isolated after the Folder for iTunes.
So, if such is the case, then with Windows, perform something similar to my above reply, with Command Prompt.
turingtest2 Said:
"There is no way to get a playlist stored in iTunes to interact with the Windows Command Prompt. A playlist in iTunes is an ordered list of references to track objects.[...]"
-------
Then put all my replies aside - seems its a matter of getting within the folder to view a file's location. Nothing of the file, but the name itself, and where its located. Once located, then open the file and proceed from there.
If you could modify the script so that it only shows the file path and name within the iTunes Media folder, that would be great. Thank you.
It seems weird that the playlist view does not show the file name You can modify the view to show information about the file, like size, bit rate, sample rate, and kind, but not the name of the file itself.
I don't need the full path, all the files are in the default iTunes Media folder, so I just the path name after that. Thanks for any help you can offer.
You're welcome. 🙂
tt2
Printing files used by a playlist