PlaySound('c:\source\Sounds\blip.wav')
PROCEDURE PlaySound( tcWavFile, tnFlags )
* play synchronously (default) */
#define SND_SYNC 0x0000
* play asynchronously */
#define SND_ASYNC 0x0001
* silence (!default) if sound not found */
#define SND_NODEFAULT 0x0002
* pszSound points to a memory file */
#define SND_MEMORY 0x0004
* loop the sound until next sndPlaySound */
#define SND_LOOP 0x0008
* don't stop any currently playing sound */
#define SND_NOSTOP 0x0010
* don't wait if the driver is busy */
#define SND_NOWAIT 0x00002000
* name is a registry alias */
#define SND_ALIAS 0x00010000
* alias is a predefined ID */
#define SND_ALIAS_ID 0x00110000
* name is file name */
#define SND_FILENAME 0x00020000
* name is resource name or atom */
#define SND_RESOURCE 0x00040004
*#if(WINVER >= 0x0400)
* purge non-static events for task */
#define SND_PURGE 0x0040
* look for application specific association */
#define SND_APPLICATION 0x0080
*#endif /* WINVER >= 0x0400 */
DECLARE INTEGER PlaySound IN WinMM.dll AS PS_API ;
STRING @ pszSound, INTEGER HMODULE_hmod, LONG DWORD_fdwSound
LOCAL lnFlags
lnFlags = iif( vartype(tnFlags)='N', tnFlags, SND_ASYNC+SND_FILENAME )
PS_API(tcWavFile,0,lnFlags)
ENDPROC