windows media player problem

M

Messer

hello,

i'd like my application to play video "friday.wmv" just after "monday.wmv".
i don't want to use a playlist. the wmp is deaf just after playing the first
video. what am i doing wrong?
windows xp, wmp 9

the code:

Private Sub Form1_Load(ByVal sender As Object, ByVal e As System.EventArgs)
Handles MyBase.Load

player.URL = "c:\temp\monday.wmv"

player.Ctlcontrols.play()

End Sub

Private Sub player_PlayStateChange(ByVal sender As Object, ByVal e As
AxWMPLib._WMPOCXEvents_PlayStateChangeEvent) Handles player.PlayStateChange

If e.newState = 1 Then

player.URL = "c:\temp\friday.wmv"

player.Ctlcontrols.play()

End If

End Sub
 
D

Dr Lomax

In the PlayStateChange function, we probably need to check the state
where playstate = mediaended or stopped and then execute your code in
there. I think that should work.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top