This is a discussion on Reading WMV file meta data in .Net within the C# Programming forums, part of the Software Development category; Reading WMV file metadata is quite simple when we using the WindowsMediaPlayerClass. I have given the Steps below. here in ...
| |||||||
| Register | FAQ | Members List | Calendar | Mark Forums Read |
| |||
| Reading WMV file metadata is quite simple when we using the WindowsMediaPlayerClass. I have given the Steps below. here in this sample code i have stored the metadata in a datagridview. 1. Open a Window Application project in .NET 2.0 2. Add Windows Media Player (WMP.dll) component reference to the project 3. Place a datagridview control in the form 4. Add a button the form. 5. Copy the below code snippets and paste it in the button click event WMPLib.WindowsMediaPlayerClass mediaPlayer = new WMPLib.WindowsMediaPlayerClass(); WMPLib.IWMPMedia mediaItem = mediaPlayer.add(@"D:\samplefile.wmv"); DataTable dtc = new DataTable(); DataRow drc; dtc.Columns.Add(new DataColumn("Property", typeof(string))); dtc.Columns.Add(new DataColumn("Value", typeof(string))); for (Int32 attrIndex = 0; attrIndex < mediaItem.attributeCount; attrIndex++) { drc = dtc.NewRow(); drc[0] = mediaItem.getAttributeName(attrIndex); drc[1] = mediaItem.getItemInfo(mediaItem.getAttributeName(a ttrIndex)); dtc.Rows.Add(drc); } DataView dvc = new DataView(dtc); dataGridView1.DataSource = dvc; |
| Sponsored Links |
![]() |
| Thread Tools | |
| Display Modes | |
| |
LinkBacks (?)
LinkBack to this Thread: http://www.discussweb.com/c-programming/1721-reading-wmv-file-meta-data-net.html | |||
| Posted By | For | Type | Date |
| Oxygen_dweb's bookmarks on del.icio.us | This thread | Refback | 08-02-2007 06:23 AM |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Reading IPTC data from Nikon camera RAW images,JPEG,TIFF files using Adobe dll in C# | oxygen | C# Programming | 1 | 02-28-2008 11:33 PM |
| Reading and Writing to File using UTL_FILE in ORACLE | Murali | Database Support | 2 | 08-23-2007 11:12 PM |
| reading data from a file using C# | oxygen | C# Programming | 2 | 08-23-2007 01:48 AM |
| Which is faster- Reading word size data whose starting address is at even or at odd a | Arun | Computer Hardware | 0 | 07-18-2007 09:03 AM |
| Reading and writing EXIF meta data from jpg/jpeg,tiff images | oxygen | C# Programming | 0 | 07-15-2007 11:24 PM |