Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I've been trying to write some code which will start playing an audio file and then stop after a certain number of seconds. I've tried this:-
sub testcode () Dim wmp as WindowsMediaPlayer Set wmp = New WindowsMediaPlayer wmp.URL = "C:\audio\test.mp3" wmp openPlayer (wmp.URL) Application.Wait Now() + TimeSerial(0, 0, 10) wmp.Controls.stop End Sub It opens the player ok and plays the file but then it doesn't stop after 10 sec. wmp.playState tells me it is stopped - but the player keeps going. Is wmp.Controls.stop the wrong command? I'm not too experienced with this sort of thing so I may be making a really silly mistake. Can anyone tell me what it is? |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
windows media player commands | Excel Discussion (Misc queries) | |||
Close Windows Media Player | Excel Discussion (Misc queries) | |||
Media Player versus Windows Media Player | Excel Programming | |||
Media Player versus Windows Media Player | Excel Discussion (Misc queries) | |||
Excel windows media player links | Excel Programming |