OK, this one has been driving me up the wall for a while now.
I have a WMP control and a listview. Simple enough.
What I am trying to do is allow the user to double-click an item in the listview, and add it to a playlist (begin playing it in the WMP control). I have tried numerous ways to do this, and all of them give an error saying that it cannot cast the type String to WMPlayer (or whatever the name of the WMP control backend is called).
Avoiding sounding like a total idiot, here is the current code that I have (that is still a total FAIL)
Private Sub ListView1_DoubleClick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ListView1.DoubleClick
'Playlist = Player.newPlaylist("myPlayList", "")
'Player.currentPlaylist = ListView1.SelectedIndices
'InfoLabel.Visible = False
Dim Playlist As IWMPPlaylist = ListView1.SelectedItems.ToString
'Dim theMedia = libForm.TheMedia
Playlist = Player.currentPlaylist
' Set the current media. It will play automatically.
Player.currentMedia = Playlist
Anyone got a tutorial on this? Ideas? Am I a total oblivious idiot and am missing one line of code???