PluginsGetByIndex Method (MItemClass)
index of plugin
Gets the plugin by its index.
Syntax
Public Overridable Sub PluginsGetByIndex( _
   ByVal _nIndex As Integer, _
   ByRef _ppPlugin As Object, _
   ByRef _pllCallbackUserData As Long _
) 
public virtual void PluginsGetByIndex( 
   int _nIndex,
   out object _ppPlugin,
   out long _pllCallbackUserData
)
public procedure PluginsGetByIndex( 
    _nIndex: Integer;
   Out  _ppPlugin: TObject;
   Out  _pllCallbackUserData: Int64
); virtual; 
public: virtual void PluginsGetByIndex( 
   int _nIndex,
   [PARAMFLAG::Out] IUnknown* _ppPlugin,
   [PARAMFLAG::Out] long _pllCallbackUserData
) 

Parameters

_nIndex
index of plugin
_ppPlugin
_pllCallbackUserData
Example

Here is example of how to remove all plugins:

Dim myPlug As Object
Dim myCookie As Integer
Dim nCount As Integer
myPlaylist.PluginsGetCount(nCount)
For i As Integer = 0 To nCount - 1
myPlaylist.PluginsGetByIndex(i, myPlug, myCookie)
myPlaylist.PluginsRemove(myPlug)
Next
object myPlug;
int myCookie;
int nCount;
myPlaylist.PluginsGetCount(out nCount);
for (int i=0; i<nCount; i++)
{
myPlaylist.PluginsGetByIndex(i, out myPlug, out myCookie);
myPlaylist.PluginsRemove(myPlug);
}
var
myPlug: TObject;
nCount, i, myCookie: integer;
myPlugins: IMPlugins;
begin
myPlugins:= myPlaylist as IMPlugins;
myPlugins.PluginsGetCount(nCount);
for i:=0 to nCount-1 do
begin
myPlugins.PluginsGetByIndex(i, myPlug, myCookie);
myPlugins.PluginsRemove(myPlug);
end;
end;
See Also

Reference

MItemClass Class
MItemClass Members