I would like to extract the first timecode from a .wmv file. Currently i'm using this piece of code :
var wmp = new WindowsMediaPlayer();
wmp.newMedia(filename);
WMPLib.IWMPControls3 controls = (WMPLib.IWMPControls3)wmp.controls;
Thread.Sleep(5000);
Console.WriteLine(controls.currentPosition);
Console.WriteLine(controls.currentPositionTimecode);
The output is always 0 and [00000]00:00:00.00 and I don't know what am I doing wrong.