AudioTrack Class
[ This article is for Windows Phone 8 developers. If you’re developing for Windows 10, see the latest documentation. ]
Represents a single track of audio.
Assembly: Microsoft.Phone (in Microsoft.Phone.dll)
XMLNS for XAML: Not mapped to an xmlns.
The AudioTrack type exposes the following members.
| Name | Description | |
|---|---|---|
![]() | AudioTrack() | Creates a new instance of the AudioTrack class. |
![]() | AudioTrack(Uri, String, String, String, Uri) | Creates and initializes a new instance of the AudioTrack class. |
![]() | AudioTrack(Uri, String, String, String, Uri, String, EnabledPlayerControls) | Creates and initializes a new instance of the AudioTrack class. |
| Name | Description | |
|---|---|---|
![]() | Album | Text to display as the track’s album. |
![]() | AlbumArt | The path to the album art for the track. |
![]() | Artist | Text to display as the track's artist. |
![]() | Duration | The length of the track. |
![]() | PlayerControls | Determines which playback controls are enabled in the system user interface. |
![]() | Source | The URI path to the track. |
![]() | Tag | An arbitrary string associated with this track, used to store application-specific state. |
![]() | Title | Text to display as the track's title. |
| Name | Description | |
|---|---|---|
![]() | BeginEdit | Sets the track object into edit mode. |
![]() | CancelEdit | This method is not implemented for AudioTrack objects and always throws a NotSupportedException. |
![]() | EndEdit | Ends an edit operation, saving all property changes to the underlying store. |
![]() | Equals(Object) | Determines whether the specified Object is equal to the current Object. (Inherited from Object.) |
![]() | Finalize | Allows an object to try to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection. (Inherited from Object.) |
![]() | GetHashCode | Serves as a hash function for a particular type. (Inherited from Object.) |
![]() | GetType | Gets the Type of the current instance. (Inherited from Object.) |
![]() | MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) |
![]() | ToString | Returns a string that represents the current object. (Inherited from Object.) |
This class makes use of IEditableObject to enable batching of property change requests. For example, when a track changes, the application may want to update several pieces of metadata all at once, such as track name, artist, album, and so on.
Once the track has been created using one of the AudioTrack constructors, then the BeginEdit() and EndEdit() methods must be used to update the object.


