Interface IMediaControl
Web methods for playing media (audio/video) files embedded in the HTML page.
public interface IMediaControl
Properties
CurrentSource
The URL of this media file, which is currently selected in the browser window.
string CurrentSource { get; }
Property Value
Duration
The length of the currently selected media file (in milliseconds).
uint Duration { get; }
Property Value
HasAutoPlay
Indicates whether this media file starts playing as soon as it loads.
bool HasAutoPlay { get; }
Property Value
HasPlaybackControls
Indicates whether this media player should display playback controls.
bool HasPlaybackControls { get; }
Property Value
IsMuted
Indicates whether the media volume is muted.
bool IsMuted { get; }
Property Value
IsPlayInLoop
Indicates whether this media file should start playing again from the beginning as soon as it finishes playing.
bool IsPlayInLoop { get; }
Property Value
IsPlaying
Indicates whether this media file is currently playing.
bool IsPlaying { get; }
Property Value
PlaybackRate
Indicates the speed of the media playback.
double PlaybackRate { get; }
Property Value
Remarks
Possible values: Numbers with up to two decimal places. For example, 0.51 or 1.00.
PlaybackTime
The current playback position in the media file (in milliseconds).
uint PlaybackTime { get; }
Property Value
Sources
A collection of all media file source URLs.
string[] Sources { get; }
Property Value
- string[]
Remarks
A media file may have multiple URL addresses for use in different browser types.
If the src attribute was set, but no sources were defined in the HTML, the Sources property will return a collection containing a single item with the "src" value.
Volume
Indicates the volume used when playing this media file.
double Volume { get; }
Property Value
Remarks
Possible values: Numbers with up to two decimal places. For example, 0.51 or 1.00.
Methods
Pause()
Pauses the media playback.
void Pause()
Play()
Plays the media file.
void Play()
Reload()
Reloads the media file.
void Reload()