Im trying to send out information to FM and DAB about what kind of news items are played from mAirlist. This is dummy files that are updated with new content every hour, and the news headlines is stored online.
I imagine that the “comment field” can be updated by receiving the correct information from SQL base or text file, and to send the “comment field” out instead of artist/title when category is “News”.
Does anyone know if it is possible to update items comment field when item is played or loaded, from external file? Ex. when national news are playing fill the comment field with text from: http://radioene.no/onair/hedmark.txt
Traverse playlist, look for item with ID 1234, and load comment via HTTP:
var
i: integer;
begin
CurrentPlaylist.BeginRead;
try
for i := 0 to CurrentPlaylist.GetCount - 1 do
if CurrentPlaylist.GetItem(i).GetDatabaseID = '1234' then
CurrentPlaylist.GetItem(i).SetComment(HTTPGet('http://1.2.3.4/something.txt'));
finally
CurrentPlaylist.EndRead;
end;
end.