我有这个代码
If AxWindowsMediaPlayer1.playState = WMPLib.WMPPlayState.wmppsStopped Then
tempInt = gen.Next(0, listTracks.Items.Count - 1)
currentTrack = tempInt
If tempInt = playedBefore Then
tempInt = gen.Next(0, listTracks.Items.Count - 1)
currentTrack = tempInt
AxWindowsMediaPlayer1.URL = listTracks.Items(tempInt)
'here > MessageBox.Show(AxWindowsMediaPlayer1.URL)
AxWindowsMediaPlayer1.Ctlcontrols.play()
playedBefore = currentTrack
Else
currentTrack = tempInt
AxWindowsMediaPlayer1.URL = listTracks.Items(tempInt)
'here > MessageBox.Show(AxWindowsMediaPlayer1.URL)
AxWindowsMediaPlayer1.Ctlcontrols.play()
playedBefore = currentTrack
End If
当歌曲结束时,下一首歌曲不播放。但是当我在消息框中显示歌曲的网址时,它将播放(标记为代码)