Script changes for V3

All three of the short scripts below work perfectly with V2 but not with V3.

I’ve not been able to find info on how to amend them, does anyone know?

// Load the current hour’s Playlist from StationPlaylist Creator
begin
Playlist(0).LoadFromM3U(‘E:\Playlists’ + FormatDateTime(‘ddd dd mmm - hh’, now) + ‘.m3u’);
SystemLog(‘Loaded Current Playlist ’ + FormatDateTime(‘ddd dd mmm - hh’, now) + ’ for playout/automation…’);
end.

// Append Next Hour Playlist
begin
CurrentPlayList.Appendplaylist(Factory.CreatePlayListFromFile(‘E:\playlists’ + FormatDateTime(‘ddd dd mmm - hh’, now + 0.04166) + ‘.m3u’));
end.

//Jump To Start Of The Hour
var i: integer;

begin
for i := 0 to CurrentPlaylist.GetCount - 1 do
if copy(CurrentPlaylist.GetItem(i).GetTitle, 1, 13) = ‘START OF HOUR’ then begin
CurrentPlaybackControl.AutomationJump(CurrentPlaylist.GetItem(i));
break;
end;
end.

Instead of “LoadFromM3U”, just use “LoadFromFile”, the correct import filter will be determined by the file extension.

“AppendPlaylist” is now simply “Append” (because IPlaylist is now based on a generic list interface also used for event lists, action lists, etc. which comes with a universal Append method).

The third script works fine here.

Thank you, that did it.