Runs an action on the recorder or dictaphone found on the current device.
Remark: This function is only available if the current device has a recorder.
// Read the sound file named "Music.3gpp"
<Result> = RecorderAction(<Action> [, <File name>])
If an error occurs, the ErrorOccurred variable is set to True. To get more details on the error, use ErrorInfo.
- True if the specified action was started,
- False otherwise.
<Action>: Integer constant
Type of action to perform:
|recorderClose||Closes the recorder.|
|recorderPlay||Opens the recorder and plays the specified sound file.|
|recorderRecord||Opens the recorder and starts recording.|
The recording starts when the user presses the button that calls RecorderAction.
|recorderStop||Stops the current recording.|
The recording stops when the user releases the button that calls RecorderAction.
<File name>: Optional character string
Name and full path of the sound file:
- to record (recorderRecord constant).
- to play (recorderPlay constant).
This file has the following format:
- ".3gpp" in Android.
- ".WAV" in iPhone/iPad.
The call to this function modifies the permissions required by the application.
Required permission: RECORD_AUDIO
This permission is used to record the sounds.