mmsystem

mmsystem

am 29.01.2008 04:02:00 von Dominic Vella

Does anyone know why I would be getting a "File not found: mmsystem"?

I've tried this:
Declare Function sndPlaySound Lib "mmsystem" (ByVal lpszSoundName As
String, ByVal wFlags As Integer) As Integer

I can see 'mmsystem.dll' in my "c:\windows\system" directory

I really want to use the 'mmsystem' library because of it's high level
Timing and I'd rather not go the WINMM direction as it doesn't have other
great functions I want to use.

Thanks in advance.


Dominic

Re: mmsystem

am 29.01.2008 09:25:20 von CDMAPoster

On Jan 28, 10:02=A0pm, "Dominic Vella"
wrote:
> Does anyone know why I would be getting a "File not found: mmsystem"?
>
> I've tried this:
> =A0Declare Function sndPlaySound Lib "mmsystem" (ByVal lpszSoundName As
> String, ByVal wFlags As Integer) As Integer
>
> I can see 'mmsystem.dll' in my "c:\windows\system" directory
>
> I really want to use the 'mmsystem' library because of it's high level
> Timing and I'd rather not go the WINMM direction as it doesn't have other
> great functions I want to use.
>
> Thanks in advance.
>
> Dominic

This is a shot in the dark.

Steven Roman, in his book "Win32 API Programming With Visual
Basic" (ISBN: 1-56592-631-5, maybe also 9781565926318) states:

For Win32 API calls, this is usually (but not always) one of the "big
three":

KERNEL32.DLL
USER32.DLL
GDI32.DLL

For these three DLLs, you can omit the extension .DLL in , as
we did ...

James A. Fortune
CDMAPoster@FortuneJames.com

Re: mmsystem

am 29.01.2008 09:39:33 von arracomn_o_s_p_a_m

"Dominic Vella" schreef in bericht =
news:479e968f$0$17825$afc38c87@news.optusnet.com.au...
> Does anyone know why I would be getting a "File not found: mmsystem"?
>=20
> I've tried this:
> Declare Function sndPlaySound Lib "mmsystem" (ByVal lpszSoundName As=20
> String, ByVal wFlags As Integer) As Integer
>=20
> I can see 'mmsystem.dll' in my "c:\windows\system" directory
>=20
> I really want to use the 'mmsystem' library because of it's high level =

> Timing and I'd rather not go the WINMM direction as it doesn't have =
other=20
> great functions I want to use.
>=20
> Thanks in advance.
>=20
>=20
> Dominic
>=20

This works for me to play files:

Private Declare Function apiPlaySound Lib "Winmm.dll" Alias =
"sndPlaySoundA" _
(ByVal lpszSoundName As String, ByVal uFlags As Long) As Long

Function csvPlayWave(ByVal FileName As String, ByVal How As Integer) As =
Integer
csvPlayWave =3D apiPlaySound(Trim(FileName), How)
end Function

'Example: ReturnCode =3DcsvPlayWave("c:\windows\media\tada.wav", 1)

Arno R

Re: mmsystem

am 29.01.2008 10:09:23 von Dominic Vella

As I mentioned, I was trying to avoid the WinMM. Basically, I'm trying to
synchronise playback (particularly MIDI) with other activity. MMSystem is
a lower level platform, of which WinMM also uses (supposedly).

I need MMSystem for such functions as MidiInOpen, MidiInStart,
MidiInAddBuffer, PutMidiOut etc.

Dom


"Arno R" wrote in message
news:479ee64f$0$25485$ba620dc5@text.nova.planet.nl...

"Dominic Vella" schreef in bericht
news:479e968f$0$17825$afc38c87@news.optusnet.com.au...
> Does anyone know why I would be getting a "File not found: mmsystem"?
>
> I've tried this:
> Declare Function sndPlaySound Lib "mmsystem" (ByVal lpszSoundName As
> String, ByVal wFlags As Integer) As Integer
>
> I can see 'mmsystem.dll' in my "c:\windows\system" directory
>
> I really want to use the 'mmsystem' library because of it's high level
> Timing and I'd rather not go the WINMM direction as it doesn't have other
> great functions I want to use.
>
> Thanks in advance.
>
>
> Dominic
>

This works for me to play files:

Private Declare Function apiPlaySound Lib "Winmm.dll" Alias "sndPlaySoundA"
_
(ByVal lpszSoundName As String, ByVal uFlags As Long) As Long

Function csvPlayWave(ByVal FileName As String, ByVal How As Integer) As
Integer
csvPlayWave = apiPlaySound(Trim(FileName), How)
end Function

'Example: ReturnCode =csvPlayWave("c:\windows\media\tada.wav", 1)

Arno R

Re: mmsystem

am 29.01.2008 10:51:34 von arracomn_o_s_p_a_m

"Dominic Vella" schreef in bericht =
news:479eeca8$0$13919$afc38c87@news.optusnet.com.au...
> As I mentioned, I was trying to avoid the WinMM. =20

Sorry, I overlooked that one

Arno R

Re: mmsystem

am 29.01.2008 15:29:20 von Tom van Stiphout

On Tue, 29 Jan 2008 14:02:00 +1100, "Dominic Vella"
wrote:

I have the file on my system as well, both in system and system32, but
both say "No PE signature found. This file is not a valid Win32
module" when I try to inspect them. I suspect they are 16-bit legacy
components. You'd need to find more modern replacements.

-Tom.



>Does anyone know why I would be getting a "File not found: mmsystem"?
>
>I've tried this:
> Declare Function sndPlaySound Lib "mmsystem" (ByVal lpszSoundName As
>String, ByVal wFlags As Integer) As Integer
>
>I can see 'mmsystem.dll' in my "c:\windows\system" directory
>
>I really want to use the 'mmsystem' library because of it's high level
>Timing and I'd rather not go the WINMM direction as it doesn't have other
>great functions I want to use.
>
>Thanks in advance.
>
>
>Dominic
>

Re: mmsystem

am 30.01.2008 01:00:40 von Dominic Vella

Yes, MMSystem is 16-bit. To my understanding it was still useable as when
developing Win95 they rushed and allowed some 16-bit dll's. The WinMM dll
typically Thunked (a techo name for mutating) the 16-bit MMSystem dll.

Now it seems, I'm way behind the times, WinMM has been fixed and fortunately
uses the same library calls. No more thunking!! Yippee.


Dominic

"Tom van Stiphout" wrote in message
news:1tdup35g3pnmu3em2663gmkm30gided4jf@4ax.com...
> On Tue, 29 Jan 2008 14:02:00 +1100, "Dominic Vella"
> wrote:
>
> I have the file on my system as well, both in system and system32, but
> both say "No PE signature found. This file is not a valid Win32
> module" when I try to inspect them. I suspect they are 16-bit legacy
> components. You'd need to find more modern replacements.
>
> -Tom.
>
>
>
>>Does anyone know why I would be getting a "File not found: mmsystem"?
>>
>>I've tried this:
>> Declare Function sndPlaySound Lib "mmsystem" (ByVal lpszSoundName As
>>String, ByVal wFlags As Integer) As Integer
>>
>>I can see 'mmsystem.dll' in my "c:\windows\system" directory
>>
>>I really want to use the 'mmsystem' library because of it's high level
>>Timing and I'd rather not go the WINMM direction as it doesn't have other
>>great functions I want to use.
>>
>>Thanks in advance.
>>
>>
>>Dominic
>>