Thread: WAV Files
View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Paige Paige is offline
external usenet poster
 
Posts: 270
Default WAV Files

I have a macro to play a wav file; however, I only want to play the first 30
seconds from it. Is there a way to modify my macros (see below) to stop
after 30 seconds?

Declare Function sndPlaySound32 Lib "winmm.dll" Alias "sndPlaySoundA" _
(ByVal lpszSoundName As String, ByVal uFlags As Long) As Long

Sub GameOver()
Call sndPlaySound32("C:\Sounds\Gameover.wav", 0)
End Sub