SteveS
Nov 4th, 1999, 08:29 AM
OK, recording "Mic" to a .Wav File.
NOTE: This will record everything heard on the speakers. So make sure the CD etc... is stopped.
Public Sub RecordWave(Filename As String)
'Filename: file to save wave as
On Local Error Resume Next
Dim varVoid As Long
Dim RetStr As String
Dim varT#
RetStr = Space$(64)
varVoid = mciSendString("open new type waveaudio alias capture", RetStr, 64, 0)
varVoid = mciSendString("record capture", RetStr, 64, 0)
'1 Millisecond capture
varT# = Timer + 1
Do Until Timer > varT#
DoEvents
Loop
varVoid = mciSendString("save capture " & filename, RetStr, 64, 0)
End Sub
Hope this helps,
Steve.
NOTE: This will record everything heard on the speakers. So make sure the CD etc... is stopped.
Public Sub RecordWave(Filename As String)
'Filename: file to save wave as
On Local Error Resume Next
Dim varVoid As Long
Dim RetStr As String
Dim varT#
RetStr = Space$(64)
varVoid = mciSendString("open new type waveaudio alias capture", RetStr, 64, 0)
varVoid = mciSendString("record capture", RetStr, 64, 0)
'1 Millisecond capture
varT# = Timer + 1
Do Until Timer > varT#
DoEvents
Loop
varVoid = mciSendString("save capture " & filename, RetStr, 64, 0)
End Sub
Hope this helps,
Steve.