Clear Playlist in ActiveX Control

Microsoft Windows specific usage questions
Forum rules
Please post only Windows specific questions in this forum category. If you don't know where to post, please read the different forums' rules. Thanks.
InsureMan
Blank Cone
Blank Cone
Posts: 40
Joined: 09 Oct 2008 11:54

Clear Playlist in ActiveX Control

Postby InsureMan » 07 Mar 2009 13:05

Have VLC as an ActiveX embedded in an Access form and control VLC with Access VB code. Have Access load 20 media files and the playing and navigating through these is fine. My issue is that if I use the following code to try and clear the Playlist:

Public mobjPlayer As VLCPlugin2

Set mobjPlayer = Me!VLCPlayer.Object
With mobjPlayer
.playlist.Clear
End With

Then run the:
Dim lngX As Long
Set mobjPlayer = Me!VLCPlayer.Object
lngX = mobjPlayer.playlist.items.Count()
MsgBox "There is " & lngX & " Items in Playlist", vbInformation, ""

to check if no files are still loaded and the reporting is Nil

If I then load a new bunch of files and then go and play these it always starts with the very last files I was playing. It would seem that there is a residual entry left in the Playlist. Can someone assist with code that will completely empty the Playlist.

Thanks

InsureMan
Blank Cone
Blank Cone
Posts: 40
Joined: 09 Oct 2008 11:54

Re: Clear Playlist in ActiveX Control

Postby InsureMan » 08 Mar 2009 09:42

Problem Solved - After Adding new entries to Playlist ran code in this order

.playlist.playItem (0)
.playlist.Next

This moved to the start of the new entries


Return to “VLC media player for Windows Troubleshooting”

Who is online

Users browsing this forum: No registered users and 64 guests