From: Bernd.Specht@gmx.com (Bernd Specht)
Subject: Re: playsound
Date: 24 Jun 2005 19:16:56 GMT
Date: 2005-06-24T21:16:56+02:00 [thread overview]
Message-ID: <Xns967FD85BEBC58BerndSpechgmxcom@151.189.20.10> (raw)
In-Reply-To: e465bcf0.0506240558.5f62f511@posting.google.com
sisi.ard@laposte.net (Sylvain) wrote in news:e465bcf0.0506240558.5f62f511
@posting.google.com:
> Can you give me a piece of code which explain me how to use the
> Playsound API please ?
>
> Thx, Bye !
>
First do a with for the bindings:
with Win32.Mmsystem;
Then call PlaySound like this:
...
xBool : Win32.BOOL;
SoundFName : String := "ringin.wav" & Ascii.Nul;
function AdrToLpcstr is new Unchecked_Conversion (System.Address,
Win32.LPCSTR);
begin
Conn := Get_Router_State;
if Conn = Is_Connected
then
xBool := Win32.Mmsystem.PlaySound (AdrToLpcstr
(SoundFName'Address), System.Null_Address, Win32.Mmsystem.SND_FILENAME);
end if;
...
prev parent reply other threads:[~2005-06-24 19:16 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-06-24 13:58 playsound Sylvain
2005-06-24 14:39 ` playsound Adrien Plisson
2005-06-24 19:16 ` Bernd Specht [this message]
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox