Code: Select all
sdb.player.playlistaddtracks(SDB.AllVisibleSongList)So my questions are:
1. Is this the best way, regarding performance, to do this?
2. Is there a scripting mechanism to initiate the playnow function that's available as a right-click function or a shortcut, ie Alt-Enter ?
Thanks!
Ray
Code: Select all
Option Explicit
Sub OnStartup
Dim itm3
Set itm3 = SDB.UI.AddMenuItem(SDB.UI.Menu_Pop_Tree,0,0)
itm3.Caption = "Play Selection"
itm3.OnClickFunc = "PlaySelected"
itm3.UseScript = Script.ScriptPath
itm3.IconIndex = 25
itm3.Visible = True
End Sub
Sub PlaySelected(arg)
dim starttimer
starttimer=timer()
sdb.player.stop
sdb.player.playlistclear
sdb.player.playlistaddtracks(SDB.AllVisibleSongList)
sdb.player.play
msgbox(timer()-starttimer)
End Sub