Introduction
Windows 8 Apps have a good control for playing audio & videos in applications. I have integrated a Media Control in this sample and used several methods to make it work.
To embed a music or video player in your application we use the “MediaElement class”. I also created customized controls to give more functionality such as play, pause, volume +, Volume – and Stop.
You can use also “enable full-screen mode” when you use a video. I used the MediaElement class to control and manage audio media playback in a Windows Store app using C#.
In this sample the MediaElement class has the following methods:
- Pause: Pauses media at the current position.
- Play: Plays media from the current position.
- Stop: Stops and resets media to be played from the beginning.
The MediaElement class has these properties:
IsMuted Gets or sets a value indicating whether the audio is muted.
Volume Gets or sets the media’s volume.
Description
I’ve used Visual Studio Ultimate 2012 and used the following 5 buttons:
| Button | Click handler action |
| Play | Calls the Play method. |
| Pause | Calls the Pause method. |
| Stop | Calls the Stop method. |
| Vol – | Volume Down |
| Vol + | Volume Up |
And one MediaElement (Name property: Media).
C# Code

Yuki YukiPosted Jan 5, 2018, 7:04 PM
You have playgrised, almost word for word copied from msdn article.
Santhakumar MunuswamyPosted Jun 24, 2015, 11:34 PM
Thanks for sharing