Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
playing wma files
I have my wav sounds playing quite nicely, using the following code. However,
one of the files I would to play is a wma file. Just changing the code below to Fart.wma from Fart.wav doesn't do it. Does anyone have an idea on this one? Regards, Brett Option Explicit Private Declare Function PlaySound Lib "winmm.dll" Alias "PlaySoundA" (ByVal lpszName As String, ByVal hModule As Long, ByVal dwFlags As Long) As Long Const SND_SYNC = &H0 Const SND_ASYNC = &H1 Const SND_FILENAME = &H20000 Sub WAV_OOPS() Dim WAVFile As String WAVFile = "C:\QUO SOUNDS\Fart.wav" Call PlaySound(WAVFile, 0&, SND_ASYNC Or SND_FILENAME) End Sub |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
playing wma files
Sub playit()
ActiveWorkbook.FollowHyperlink Address:="C:\Documents and Settings\Owner\Desktop\Sugar Magnolia.wma" End Sub Gets me a small piece of the Grateful Dead. -- Gary''s Student - gsnu200836 "Brettjg" wrote: I have my wav sounds playing quite nicely, using the following code. However, one of the files I would to play is a wma file. Just changing the code below to Fart.wma from Fart.wav doesn't do it. Does anyone have an idea on this one? Regards, Brett Option Explicit Private Declare Function PlaySound Lib "winmm.dll" Alias "PlaySoundA" (ByVal lpszName As String, ByVal hModule As Long, ByVal dwFlags As Long) As Long Const SND_SYNC = &H0 Const SND_ASYNC = &H1 Const SND_FILENAME = &H20000 Sub WAV_OOPS() Dim WAVFile As String WAVFile = "C:\QUO SOUNDS\Fart.wav" Call PlaySound(WAVFile, 0&, SND_ASYNC Or SND_FILENAME) End Sub |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
playing wma files
Thanks GS (again).Brett
"Gary''s Student" wrote: Sub playit() ActiveWorkbook.FollowHyperlink Address:="C:\Documents and Settings\Owner\Desktop\Sugar Magnolia.wma" End Sub Gets me a small piece of the Grateful Dead. -- Gary''s Student - gsnu200836 "Brettjg" wrote: I have my wav sounds playing quite nicely, using the following code. However, one of the files I would to play is a wma file. Just changing the code below to Fart.wma from Fart.wav doesn't do it. Does anyone have an idea on this one? Regards, Brett Option Explicit Private Declare Function PlaySound Lib "winmm.dll" Alias "PlaySoundA" (ByVal lpszName As String, ByVal hModule As Long, ByVal dwFlags As Long) As Long Const SND_SYNC = &H0 Const SND_ASYNC = &H1 Const SND_FILENAME = &H20000 Sub WAV_OOPS() Dim WAVFile As String WAVFile = "C:\QUO SOUNDS\Fart.wav" Call PlaySound(WAVFile, 0&, SND_ASYNC Or SND_FILENAME) End Sub |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Detecting the actual playing or NOT playing of a WAV file | Excel Discussion (Misc queries) | |||
Playing a sequence of WAV files | Excel Programming | |||
playing mp3 files on user input | Excel Programming | |||
Playing .mp3 files based on user input | Excel Programming | |||
Playing .wav files (why do a few cause warning messages?) | Excel Programming |