Share via


MediaPlayer.MediaDefinition Property

Gets or sets the path of the media definition file.

Namespace:  System.Web.UI.SilverlightControls
Assembly:  System.Web.Silverlight (in System.Web.Silverlight.dll)

Syntax

'Declaration
<ThemeableAttribute(True)> _
Public Overridable Property MediaDefinition As String
    Get
    Set
'Usage
Dim instance As MediaPlayer
Dim value As String

value = instance.MediaDefinition

instance.MediaDefinition = value
[ThemeableAttribute(true)]
public virtual string MediaDefinition { get; set; }

Property Value

Type: System.String
A virtual path that represents the location of the media definition file in the current project.

Remarks

The media definition file is an XML file that contains data about the media source, such as chapter positions, chapter titles, and the path of chapter thumbnails.

Microsoft Expression Encoder can generate a media definition file when it encodes one or more videos. It saves this file and the associated images such as thumbnails to an output folder.

Media source, chapters, chapter titles, and chapter thumbnail images can be specified by using the MediaPlayer control properties or defined in a media definition file.

If any one of these settings are found in the media definition file indicated by this property, those values take precedence over the corresponding property set on the MediaPlayer control.

If there is more than one media file in a media definition file, the MediaPlayer control uses only the first media file in a media definition file. Playback ends after the first media file finishes playing.

For more information about media definition files, see ASP.NET MediaPlayer Server Control.

Platforms

For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.

See Also

Reference

MediaPlayer Class

MediaPlayer Members

System.Web.UI.SilverlightControls Namespace

Other Resources

Walkthrough: Creating a Media Definition File