Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
How can I adjust audio volume (for wav, MIDI, mp3 files) from within Excel ?
What declarations and functions would I need ? Thanks, AP |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
On Thu, 22 Jun 2006 21:31:05 +1200, AP wrote:
How can I adjust audio volume (for wav, MIDI, mp3 files) from within Excel ? For wav: Declare Function waveOutSetVolume Lib "Winmm" (ByVal wDeviceID As Integer, ByVal dwVolume As Long) As Integer Declare Function waveOutGetVolume Lib "Winmm" (ByVal wDeviceID As Integer, dwVolume As Long) As Integer Public Function GetVolume() Dim a, i As Long Dim tmp As String a = waveOutGetVolume(0, i) tmp = "&h" & Right(Hex$(i), 4) GetVolume = CLng(tmp) End Function Public Function SetVolume(vol As Long) Dim a, i As Long Dim tmp As String tmp = Right((Hex$(vol + 65536)), 4) vol = CLng("&H" & tmp & tmp) a = waveOutSetVolume(0, vol) End Function For other devices, look at the examples in ApiGuide. -- PL |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
How do I set up an audio alert in excel? | Excel Discussion (Misc queries) | |||
x log, y lin audio frequency chart | Charts and Charting in Excel | |||
Audio file in Excel | Excel Discussion (Misc queries) | |||
Playing audio, but not from the start | Excel Programming | |||
turn on audio in excel | Excel Discussion (Misc queries) |