# Record

<div align="left"><img src="https://963067965-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-MIJW5nbmYRaSNWePAac%2F-MIxu2KP4MClY9gv_q2W%2F-MIxukS0uxJwc7YhrbTr%2FProperty-Record.png?alt=media&#x26;token=2a370f6e-3080-4415-ae11-14462d5bb1a2" alt=""></div>

| Property       | Function                                                                                                                                                                                                                                                                          | Type                                                                                                                                          |
| -------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- |
| Record url     | <p>Gets saved file name with path and prefix, e.g. <code>file:///C:/Users/work/Music/29.03.2019-13.20.17.wav</code><br><br><strong>Actions editor:</strong><br><code>Property > Record > Record url</code><br><strong>Code:</strong><br><code>widget.content.recordUrl</code></p> | `string`                                                                                                                                      |
| Audio format   | <p>Holds the audio codec<br><br><strong>Actions editor:</strong><br><code>Property > Record > Audio format</code><br><strong>Code:</strong><br><code>widget.content.audioFormat</code></p>                                                                                        | `enum`                                                                                                                                        |
| File container | <p>Holds media container format<br><br><strong>Actions editor:</strong><br><code>Property > Record > File container</code><br><strong>Code:</strong><br><code>widget.content.fileContainer</code></p>                                                                             | `string`                                                                                                                                      |
| Sample rate    | <p>Holds audio sample rate in Hz<br><br><strong>Actions editor:</strong><br><code>Property > Record > Sample rate</code><br><strong>Code:</strong><br><code>widget.content.sampleRate</code></p>                                                                                  | `int`                                                                                                                                         |
| Channels       | <p>Holds number of audio channels<br><br><strong>Actions editor:</strong><br><code>Property > Record > Channels</code><br><strong>Code:</strong><br><code>widget.content.channels</code></p>                                                                                      | `int`                                                                                                                                         |
| Record state   | <p>Gets current record state<br><br><strong>Actions editor:</strong><br><code>Property > Record > Record state</code><br><strong>Code:</strong><br><code>widget.content.recordState</code></p>                                                                                    | <p><code>enum</code><br><br><strong>Values:</strong><br><code>0 - Recording</code><br><code>1 - Paused</code><br><code>2 - Stopped</code></p> |
| Elapsed time   | <p>Gets elapsed time in format MM:SS, e.g. 0:17<br><br><strong>Actions editor:</strong><br><code>Property > Record > Elapsed time</code><br><strong>Code:</strong><br><code>widget.content.elapsedTime</code></p>                                                                 | `string`                                                                                                                                      |
| Record error   | <p>Gets string describing the current error state<br><br><strong>Actions editor:</strong><br><code>Property > Record > Record error</code><br><strong>Code:</strong><br><code>widget.content.recordError</code></p>                                                               | `string`                                                                                                                                      |

## Actions

| Property     | Function                                                                                                                                                                    |
| ------------ | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Start record | <p><strong>Actions editor:</strong><br><code>Actions > Common > Start record</code><br><strong>Code:</strong><br><code>widget.content.script.actionRecordStart()</code></p> |
| Stop record  | <p><strong>Actions editor:</strong><br><code>Actions > Common > Stop record</code><br><strong>Code:</strong><br><code>widget.content.script.actionRecordStop()</code></p>   |
| Pause record | <p><strong>Actions editor:</strong><br><code>Actions > Common > Pause record</code><br><strong>Code:</strong><br><code>widget.content.script.actionRecordPause()</code></p> |

## Events

| Property       | Function                                                                                                                                                                                             |
| -------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Record started | <p>Event when record started<br><br><strong>Actions editor:</strong><br><code>Event > Record started</code><br><strong>Code:</strong><br><code>widget.content.script.eventRecordStarted()</code></p> |
| Record paused  | <p>Event when record paused<br><br><strong>Actions editor:</strong><br><code>Event > Record paused</code><br><strong>Code:</strong><br><code>widget.content.script.eventRecordPaused()</code></p>    |
| Record stopped | <p>Event when record stopped<br><br><strong>Actions editor:</strong><br><code>Event > Record stopped</code><br><strong>Code:</strong><br><code>widget.content.script.eventRecordStopped()</code></p> |
| Record error   | <p>Event when record error<br><br><strong>Actions editor:</strong><br><code>Event > Record error</code><br><strong>Code:</strong><br><code>widget.content.script.eventRecordError()</code></p>       |
