G
Guillaume
Here after was my code available in a vb module referenced
to play a sound on a specific action. Using my programm
with Windows 2000 generates an error message : "Can't find
DLL entry point SndPlaySound in winmm.dll"
Any thought ?
Private Declare Function sndPlaySound Lib "winmm.dll" _
() 'Alias "sndPlaySoundA" (ByVal lpszSoundName As String, _
ByVal uFlags As Long) As Long
Const SND_SYNC = &H0
Const SND_ASYNC = &H1
Const SND_NODEFAULT = &H2
Const SND_LOOP = &H8
Const SND_NOSTOP = &H10
Public Sub PlayLowSound()
Dim SoundFile As String
Dim wFlags As Long, x As Long
SoundFile = FlexSheet2.TxtLowerSound.Text
wFlags = SND_ASYNC Or SND_NODEFAULT
x = sndPlaySound(SoundFile, wFlags)
End Sub
Public Sub PlayHighSound()
Dim SoundFile As String
Dim wFlags As Long, x As Long
SoundFile = FlexSheet2.TxtUpperSound.Text
wFlags = SND_ASYNC Or SND_NODEFAULT
x = sndPlaySound(SoundFile, wFlags)
End Sub
to play a sound on a specific action. Using my programm
with Windows 2000 generates an error message : "Can't find
DLL entry point SndPlaySound in winmm.dll"
Any thought ?
Private Declare Function sndPlaySound Lib "winmm.dll" _
() 'Alias "sndPlaySoundA" (ByVal lpszSoundName As String, _
ByVal uFlags As Long) As Long
Const SND_SYNC = &H0
Const SND_ASYNC = &H1
Const SND_NODEFAULT = &H2
Const SND_LOOP = &H8
Const SND_NOSTOP = &H10
Public Sub PlayLowSound()
Dim SoundFile As String
Dim wFlags As Long, x As Long
SoundFile = FlexSheet2.TxtLowerSound.Text
wFlags = SND_ASYNC Or SND_NODEFAULT
x = sndPlaySound(SoundFile, wFlags)
End Sub
Public Sub PlayHighSound()
Dim SoundFile As String
Dim wFlags As Long, x As Long
SoundFile = FlexSheet2.TxtUpperSound.Text
wFlags = SND_ASYNC Or SND_NODEFAULT
x = sndPlaySound(SoundFile, wFlags)
End Sub