About Audio components
You can add an Audio component to a form and define its behavior in either designer (Web Designer in the web client, Design Mode in the Windows client). However, these components are only functional in the web client.
Component properties
Use these properties to set up or modify how the components display or behave:
Property | Description |
---|---|
Data Source > Binding | Use the Binding
property to add the audio file and to start or stop playing the file.
|
Behavior > Hidden | Use this property to hide or display the component. The default value is False, which means the component displays/plays. You must also set up the initialization string to display the audio player controls. If the component is set as visible, but has no controls, it displays an empty region. |
Behavior > ReadOnly/Disable
OR Behavior > Enabled When |
Use this property to play the audio file. The default value is False. If set to True, the start and stop functions of the player controls are enabled. Note: When player controls are displayed, its functions are
automatically enabled without enabling this property.
|
Miscellaneous > Specific Attributes > User Component Initialization String | Use this property to set up the component initialization string. |
Initialization string
In the User Component Initialization String property, specify the initialization string. Follow this format:
{"loop":value,
"controls":value, "source":value}
Use these values:
String | Value |
---|---|
loop |
The default value is false. If set to true, the
audio file continuously loops and replays. The audio file can be paused and restarted while in a continuous loop. |
controls |
The default value is false. If set to true, the
browser-specific player controls, such as play, pause, and volume options are
displayed. Note: The Hidden property must be
disabled to display the player controls.
When player controls display, its functions are always enabled. |
source |
The default value is blank. To start or play the audio file, specify the audio file's URL or data-URI. |
- Empty string:
{ }
If you enable the component and load the bound data with a valid audio URL or data-URI, the audio file will start to play as early as possible.
controls
string only:{"controls":true}
The player controls display. If you enable the component and load the bound data with a valid audio URL or data-URI, the audio file will start to play as early as possible.