MPLATFORMLib Namespace > IMPlaylist Interface : PlaylistCommandAdd Method |
Sub PlaylistCommandAdd( _ ByVal _bsCommand As String, _ ByVal _bsParam As String, _ ByVal _pTargetObject As Object, _ ByRef _pnIndex As Integer, _ ByRef _ppPlaylistItem As MItem _ )
void PlaylistCommandAdd( string _bsCommand, string _bsParam, object _pTargetObject, out int _pnIndex, out MItem _ppPlaylistItem )
procedure PlaylistCommandAdd( _bsCommand: String; _bsParam: String; _pTargetObject: TObject; Out _pnIndex: Integer; Out _ppPlaylistItem: MItem );
void PlaylistCommandAdd( BSTR* _bsCommand, BSTR* _bsParam, IUnknown* _pTargetObject, [PARAMFLAG::Out] int _pnIndex, [PARAMFLAG::Out] MItem* _ppPlaylistItem )
Here is example of how to add command to the playlist:
Dim myIndex As Integer = -1 Dim myItem As MItem Dim strPath As String Dim dblPos As Double myPlaylist.PlaylistGetByIndex(1, dblPos, strPath, myItem) Dim myTargetItem As MItem myPlaylist.PlaylistCommandAdd("mute", "true", myItem, myIndex, myTargetItem) myTargetItem.ItemCommandExecute(myPlaylist)
int myIndex = -1; MItem myItem; string strPath; double dblPos; myPlaylist.PlaylistGetByIndex(1, out dblPos, out strPath, out myItem); MItem myTargetItem; myPlaylist.PlaylistCommandAdd("mute", "true", myItem, ref myIndex, out myTargetItem); myTargetItem.ItemCommandExecute(myPlaylist);
var myIndex: integer; myItem, myTargetItem: MItem; strPath: widestring; dblPos: double; begin myPlaylist.PlaylistGetByIndex(1, dblPos, strPath, myItem); myPlaylist.PlaylistCommandAdd('mute', 'true', myItem, myIndex, myTargetItem); myTargetItem.ItemCommandExecute(myPlaylist); end;