Quantcast
Channel: VBForums - Visual Basic 6 and Earlier
Viewing all articles
Browse latest Browse all 21103

Play next song code causes problems

$
0
0
Hi,

I'm in the process of converting my mini media player that current uses Windows Media Player to use the code that MarkT posted here. Every thing appears to be working expect for this code used to play the next song in the list which, (from what I can remember) worked with Windows Media Player

vb Code:
  1. Public Sub nSong()
  2.  If Not player.Status = "playing" Or Not player.Status = "paused" And frmSetup.Songopt(1).Value = True Then
  3.   frmMain.mnuForward.Checked = False
  4.  frmMain.mnutrayFastForward.Checked = False
  5. 'Play the next song in the list
  6.    frmMain.lblTitle.Caption = "Title:"
  7.     frmMain.lblArtist.Caption = "Artist:"
  8.     frmMain.lblAlbum.Caption = "Album:"
  9.     frmMain.lblYear.Caption = "Year:"
  10.     frmMain.lblComment.Caption = "Comment:"
  11.     frmMain.lblGenreCode.Caption = "GenreCode:"
  12.     If s >= frmSetup.Lstsongs.ListCount And frmMain.mnuRepeat.Checked = True Then
  13.        s = 0
  14.     Else
  15.        s = s + 1
  16.     End If
  17.     play (s)
  18.  End If
  19. End Sub

Thanks,


Nightwalker

Edit:

If I disable the call to the above code the song plays fine however, if the above code is executed the song does not play.

Viewing all articles
Browse latest Browse all 21103

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>