how do i obtain any sound that is generated from the microphone or line-in ports? i kinda wanna try a .wav recorder and dont know how to record from these two ports? thanx
Printable View
how do i obtain any sound that is generated from the microphone or line-in ports? i kinda wanna try a .wav recorder and dont know how to record from these two ports? thanx
Use the mciSendString function.
VB Code:
Private Declare Function mciSendString Lib "winmm.dll" Alias "mciSendStringA" (ByVal lpstrCommand As String, ByVal lpstrReturnString As Any, ByVal uReturnLength As Long, ByVal hwndCallback As Long) As Long Private Sub cmdRecord_Click() mciSendString "open new type waveaudio Alias record", 0&, 0, 0 mciSendString "record record", 0&, 0, 0 End Sub Private Sub cmdSave_Click() mciSendString "stop record", 0&, 0, 0 mciSendString "save record C:\Windows\Desktop\MyWav.wav", 0&, 0, 0 mciSendString "close record", 0&, 0, 0 End Sub
and how do i set the format of the recorded sound?
i mean like how do i set the format to say umm 22khz,8bit?
gate keepers code will record anything coming from the sound card, he wants to record the microphone?
yeah i do want to record from the microphone!! anyone can help me? i also need to be able to control the quality of the recorded sound. is it possible?