PlaySoundFile
This command plays any mobile-supported sound file by specifying the path to the file where the file exists.
Note: For RFgen 5.1, use Device.PlaySound.
- For Windows CE, the path is the location of the Windows CE device.
- For Android and iOS, only .wav files are supported, and a copy of the source file MUST BE PLACED on the RFgen server under \ProgramData\RFgen51 or \ProgramData\RFgen52.
When the sound is played at runtime, the .wav file is first copied from the server to the client when the client connects to the server.
You can also use this command to vibrate an Android or iOS device. For details see Vibrate.
Group:Device Extensions
Syntax:
Device.PlaySoundFileFile(sPath), Device.PlaySoundFile(“Number, Vibrate”)
sPath (String) the full path where the file is stored on the RFgen server
.wav The sound wav file to be played. The duration is the duration of the .wav file.
Example:
This example is applicable for Android or iOS.
Device.PlaySoundFile("\ProgramData\RFgen52\ERROR.WAV")
This example is applicable for Windows CE:
Device.PlaySound("\Program Files\RFgen51\ERROR.WAV")