pls teach me how to play a simple .wav file using the simplest method! thanx thanx thanx
Put this in a module VB Code: Declare Function sndPlaySound Lib "winmm.dll" Alias "sndPlaySoundA" (ByVal lpszSoundName As String, ByVal uFlags As Long) As Long Public Const SND_ASYNC = &H1 ' play asynchronously Then call it like this VB Code: sWavFile = "C:\windows\media\Ding.wav" x = sndPlaySound(sWaveFile, SND_ASYNC) Greg
Declare Function sndPlaySound Lib "winmm.dll" Alias "sndPlaySoundA" (ByVal lpszSoundName As String, ByVal uFlags As Long) As Long Public Const SND_ASYNC = &H1 ' play asynchronously
sWavFile = "C:\windows\media\Ding.wav" x = sndPlaySound(sWaveFile, SND_ASYNC)
Free VB Add-In - The Reference Librarian Click Here for screen shot and download link.
kool is the wav a restricted lenth or size though?
Nope. Greg
Wicked. Thanks for the code.
Forum Rules