
How can you play wave/mp3 files ?
It's quite easy to play wavs and MIDI files and stuff with VB. Here is a
simple example of playing a wav file:
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
Private Sub Command1_Click()
Dim soundfilename As String
soundfilename = "c:\windows\media\ding.wav"
sndPlaySound soundfilename, SND_ASYNC Or SND_NODEFAULT
End Sub
By the way, you seem to be having a problem with your message software at
the moment. I can see three or four copies of each of your last two messages
here. The problem you are having sendinf me an email, though, is simply
because the email address in my messages is a dummy. I had lots and lots of
junk mail with my last email address that I just couldn't prevent, and it
was undoubtedly because I had for a long time used my real email address in
the newsgroup, which seems to be "farmed" by lots of unscrupulous people.
So, I have changed my email address now, thus eliminating all of the junk,
and I have made sure that I used a dummy email address on this group from
the very start this time.
Mike
Quote:
> Hello
> I forgot to ask something. How can you play wave or mp3 files in a visual
> basic program ?
> thanks Mike for answering my first question
> I have a problem if I want to reply on a message.
> best regards