到目前为止,我已经附上了我的代码,我的问题是所有播放列表的类型都返回“auto”或“wpl”。(这都是使用 WMPLib 参考)
mediaplayer = new WindowsMediaPlayer();
// Init. Playlists
IWMPPlaylistCollection plcollection = mediaplayer.playlistCollection;
plarray = plcollection.getAll();
int i = 0, count = plarray.count;
string[] t = new string[count];
// Here is where I want to sort out non-music playlists
// And add them to the ListBox
for (i = 0; i < count - 1; i++)
t[i] = plarray.Item(i).getItemInfo("PlaylistType");
for (i = 0; i < count; i++ )
PlaylistBox.Items.Add("" + plarray.Item(i).name);
不相关,但是如果您知道如何将播放列表附加为数据而不是字符串,那也会很有帮助:)