JavaScript
A5.audio.Recordercancel Method
Syntax
A5.audio.Recorder.cancel()
Description
Stop the current recording and do not save.
Example: Cancel the Recording for the AudioRecorderAndPlayer Control
The UX Component AudioRecorderAndPlayer control's JavaScript object can be used to cancel a recording. The _rec property of the object contains the audio recorder class methods. The JavaScript below demonstrates how to cancel a recording for an AudioRecorderAndPlayer control:
// Get the JavaScript object for the AudioRecorderAndPlayer Control
var audioObj = {dialog.object}.getControl("AUDIORECORDERANDPLAYER");
if (audioObj) {
// Cancel the recording
audioObj._rec.cancel();
}See Also