I'm getting a problem while trying to play the next song in a media player. Basicly when the media ends I want it to play the next song from a listbox but it's only part working. here is my code:
Public Sub player_PlayStateChange(ByVal sender As Object, ByVal e As AxWMPLib._WMPOCXEvents_PlayStateChangeEvent) Handles AxWindowsMediaPlayer1.PlayStateChange
If Not MediaStopped Then
If e.newState = 8 Then
lstMusic.SelectedIndex += 1
AxWindowsMediaPlayer1.URL = lstMusic.SelectedItem
It seems to select the next song when the media ends but it doesn't play the next song so I assume it has something to do with: AxWindowsMediaPlayer1.URL = lstMusic.SelectedItem
But again! I've used to code for _next and it works fine! so what's the problem?