The PlaySound function plays a sound registered under an ID at the client.
Syntax | |||||
PlaySound(ByVal ID As String, Optional ByVal Settings As SoundSettings = SND_ASYNC Or SND_NOWAIT) | |||||
Return value | |||||
Type |
Description | ||||
Long |
0 if it was carried out error-free | ||||
Parameter | |||||
Use |
Name |
Type |
Passing |
Description | |
Required |
ID |
String |
ByVal |
ID of the registered sound | |
Optional |
Settings |
SoundSettings |
ByVal |
Advanced settings | |
SoundSettings |
Play settings |
SND_SYNC |
Plays the sound synchronously and only returns afterwards |
SND_ASYNC |
Plays the sound asynchronously and returns immediately |
SND_LOOP |
Plays the sound in a loop until the next call of a sound |
SND_NODEFAULT |
No silence if the ID could not be found |
SND_NOSTOP |
Continues to play the sound even when a new sound is called |
SND_NOWAIT |
Does not wait to return even when the sound driver is busy |