Filename of a PlaylistItem

I did search around, but i can’t find any hint on how to get the name of the file of the PlaylistItem … any tip. please ? ???
Is it correct to EnableTimer in OnStartUp and also set the Interval ? And what integer value represents one second ?
works and 5000 are 5 sec

– using HTTPGetAsync leaves me with the problem, that filenames containing bad characters like & and such result in wrong values, is there a function to url encode a string or should i try to replace the bad characters and which pascal function could help me with this ?

I know i can add favorite folder, but there is also an option to add a folder browser, is ther a way to add those as favorites ?


As i get so much inspiration and help from this forum, i would like to share the little bits and bytes i produce with you all.

We often produce handmade playlist as we got special rules for our music, this might result in some subjective decisions when selecting titles and some might be played to often and some never.

Here is a first test version of what i’m doing currently, all further improvements are most likely just for our spezial need, so i post just the core functionality.

First I use a typical NotificationScript to send infos to a php script(source is just to see which computer send the info).

[code]procedure OnPlayerStart(PlayerControl: IPlayerControl; Item: IPlaylistItem);
HTTPGetAsync(‘’ + Item.GetTitle + ‘&artist=’ + Item.GetArtist );

The server saves the info to a db:

// db stuff

// convert get values

// write to db
mysql_query(“insert into logging (source,artist,title) values (’$source’,’$artist’,’$title’)”);

Now when the new playlist is put together, the following NotificationScript takes action:

[code]procedure OnStartup;

procedure OnTimer;
var artist,title,info: String;
i: integer;
for i := 0 to CurrentPlaylist.GetCount - 1 do
if copy(CurrentPlaylist.GetItem(i).GetComment, 1, 7) <> ‘Checked’ then begin
title := CurrentPlaylist.GetItem(i).GetTitle;
artist := CurrentPlaylist.GetItem(i).GetArtist;
info := HTTPGet(‘’ + artist + ‘&title=’ + title);
CurrentPlaylist.GetItem(i).SetComment('Checked ’ + info);


It is getting infos from this php script:

//db connection stuff

// convert GET values

//sql query: “order by playdate desc” to get latest “playdate” in first row
$q1=mysql_query(“select * from logging where artist=’$artist’ and title=’$title’ order by playdate desc”);

// get number of results, they equal the

//get single row to know the last playdate

// return the info
echo $num.’ mal, zuletzt: '.$a1[playdate];

Now every 5 seconds the script checks how often and when last time the title that hasn’t been checked was played and writes the info into the comment row.

This is nowhere perfect, I just wanted to share some ideas and work in progress with you all.


You must be sure that it’s actually a file and not a stream or dummy or something.

-- I know i can add favorite folder, but there is also an option to add a folder browser, is ther a way to add those as favorites ?

Add a leading + sign to the folder name.

Cool, thanks alot.