PDA

Click to See Complete Forum and Search --> : Playing Wavs, midi and mp3


WylerWolf
Feb 24th, 2001, 04:44 PM
Is it possible to do 1 function that can play Wav AND Mid or y have to use to different Function ???

What is the syntax this/these Function ???

parksie
Feb 24th, 2001, 05:10 PM
Sorry, you need separate functions. Unless you write your own, of course. MIDI is very hard to do if you're not using MCI -- getting the timing is a real nightmare.

Functions like PlaySound, mciSendString are the ones you need.

WylerWolf
Feb 24th, 2001, 05:47 PM
Yeah but want id the syntaxe of the mci function for midi and is it diferent for wav ??????

Feb 25th, 2001, 06:51 AM
try www.all-api.net.. and search for the functions

WylerWolf
Feb 25th, 2001, 07:57 PM
Public Declare Function PlaySound Lib "winmm.dll" _ Alias "PlaySoundA" (ByVal lpszName As String, ByVal_ hModule As Long, ByVal dwFlags As Long) As Long

Private Sub Command1_Click()
PlaySound "C:\Windows\Media\ctmelody.wav" _
, 0&, &H1
End Sub

Thats work for playing wav file but,
first can you explain me what the 0& and &H1 is doing
second how do I play midi file
third how do I play mp3 ?

WylerWolf
Feb 25th, 2001, 09:24 PM
Can someone juste explain me how to use the mciSendstring Function (I find out that I can play midi wav and mp3 with this function but I don't kno whow it works )!!! some exemple will be apreciate a lot !

WylerWolf
Feb 26th, 2001, 07:09 AM
Am I the only one here who is not sleeping or you guy dont know how to use de mci function ???
I need exemple plz.

parksie
Feb 26th, 2001, 11:54 AM
Easy now... ;)

I read your first message at school and so wasn't able to reply (well, a USEFUL reply :p). Check this out for more info: http://www.vb-world.net/graphics/tip55.html