.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

how do you detect which video format can be played in a wpf mediaelement?

Posted By:      Posted Date: August 28, 2010    Points: 0   Category :WPF
how do you detect which video format can be played in a wpf mediaelement?

View Complete Post

More Related Resource Links

Video: Converting Word Documents to PDF Format Using SharePoint Server 2010 and Word Services

Watch this visual how-to video as you learn how to programmatically convert Word documents to PDF format on the server by using Word Automation Services with SharePoint Server 2010. (Length: 6:15)

How to play a .mp4 video file with WPF (mediaelement) ?

I would like to play a .mp4 with WPF.Does anybody know how can I accomplish it?It can play wmv but when I try to play a .mp4 it doesn't show anything. It's strange because the Blend designer shows the first frame of the .mp4 video in the mediaelement.I can play the video with Windows Media Player...Waiting for an aswer...

No sound when playing MPEG video in MediaElement

Hi, I am writing a multimedia centre using the WPF MediaElement control, the project is very mature and going really well. However I get no audio when my player plays a .MPG file. I have tried installing lots of different codec packages on my test machine but to no avail. The same files have audio when loaded in WMP but not in my WPF application. I am developing on an XP machine and on that I get sound, but on my target machine, Windows 7, no sound! Other formats such as AVI etc do not have this problem. Any ideas? Thanks in advance

Showing Video file in a MediaElement


Dear all,

I am trying to ceollect a Video file and then display the first frame of the video in a container

The dataTemplate I use is as follow :

 <DataTemplate x:Key="<strong>LibraryItemTemplateVideo</strong>" DataType="{x:Type vm:VideoMedia}">
      <Viewbox Stretch="Uniform">
        <MediaElement Source="{Binding Path=FullName}

Video formats Supported by Mediaelement in WPF


Hi ,

 I am trying to devolep a WPF applciation which will render LIVE video. The data for the Video comes through TCP/IP from the Firmware end and is of "RAW YUV format". Can i render this using a mediaelement?

If Yes please guide me further down. Thanks in advance.

duplicate video to multiple mediaelement

I have xpab (partial trust) application with multiple initialized pages. Each of these pages includes an mediaelement with a backroundvideo. Is it possible to load the sourcevideo only once? I would like to do something like this: page1mediaelent = publicMediaelement, page2mediaelent = publicMediaelement . . . pageNmediaelent = publicMediaelement.  I cannot afford to download the same wmv video n times.   

MediaElement - Video freeze after Ctrl+Alt+Delete is pressed



Why do my video frozen when I do Ctrl+alt+delete and go back to the WPF application? Any idea?

string videoSource = "somevideofile";
MediaElement HomePageVideo;

void init()
  HomePageVideo.Source = new System.Uri(videoSource);

  HomePageGrid.IsEnabled = true;
  HomePageGrid.IsHitTestVisible = true;
  HomePageGrid.Opacity = 1;
  HomePageGrid.Visibility = Visibility.Visible;


void play()
   HomePageVideo.Position = new TimeSpan(0, 0, 18);

<Grid Name="HomePageGrid" Visibility="Hidden" Background="Black" Opacity="0">
  <MediaElement Name="HomePageVideo" Width="1280" Height="720" LoadedBehavior=

WPF save streamed video using MediaElement


I would like to stream videos, and save it to the hard disc using WPF MediaElement. 
For example, I'm using this code to play a video from the net:   
<MediaElement Source="http://some.url/video.wmv" />
I need to save somehow streamed media file to the hard disc.
Can anyone tell me how this is done?


How To Set a Date Format In GridView Using ASP.NET 2.0

A very common desire is to set a column of a gridview to display just the month, day and year of a DateTime type. The problem is the by default, the HtmlEncode property of the boundfield attribute (
The problem is that if this field is enabled, you can not pass format information to the boundfield control. That is, if you try the following code, you will not get the desired result.

How to format and update GridView and DataGrid rows using JQuery

The behavior described in this question is as expected. When you set text of a cell in grid, it directly affects HTML that is going to be rendered. When you set text value of a cell, it means that you are setting innerText of the cell. The column that GridView creates for command fields (Edit, Delete and Select) are a (anchor) or button elements. So you can see what will happen if you set text value in that cell. It will wipe out those link or button controls and replace them with simple text string.

How to detect and avoid memory and resources leaks in .NET application

Despite what a lot of people believe, it's easy to introduce memory and resources leaks in .NET applications. The Garbage Collector, or GC for close friends, is not a magician who would completely relieve you from taking care of your memory and resources consumption.

I'll explain in this article why memory leaks exist in .NET and how to avoid them. Don't worry, I won't focus here on the inner workings of the garbage collector and other advanced characteristics of memory and resources management in .NET.

MOSS 2007 Tutorials video

This link about how create sharepoint website ,blogs,team site,document lib etc

How to format datetime & date with century?

Execute the following Microsoft SQL Server T-SQL datetime, date and time formatting scripts in Management Studio Query Editor to demonstrate the usage of the multitude of temporal data formats available and the application of date / datetime functions.


How to Encrypt and Decrypt a Password using SQLSERVER 2005?(Video)

Encypt and Decrypt a Password using SQLSERVER 2005(Video)

SQL Server Backup and Restore (video)

Restore your full backup, then run a few queries before you keep restoring transaction logs. Brent shows how to use the Standby option for restores.

In this five minute video, Brent demonstrates how to do it by creating a database, populating data, and then showing what disaster recovery is like by doing RESTORE WITH STANDBY.

Program for Format Conversion of An Image

.NET provides extensive support for image conversion. Any image can be processed from one format to another. Most common formats to which .NET have support for are .BMP, .EMF, .GIF, .ICO, .JPG, .PNG, .TIF and .WMF.

Get pixel format, raw format, property id list and property items image in VB.net - C#.net.

n this simple article you will learn that how we can get pixel format, raw format, property id list and property items image in VB and C#.net.

Get Pixel Format:

Image consists of pixels to get the format of the pixel we have a property named pixel format. This property returns an enumeration of pixel format. This enumeration tells the pixel format.

To demonstrate make a window application. Drag one button and a picture box on form.

Now write the following code on Button click event:
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend