开发者

Embed Windows Media Player in WPF

I downloaded the source code from: http://diptimayapatra.wordpress.com/2010/04/05/using-windows-media-player-com-in-wpf/

I want to customize the play, buy add Play, Pause and Stop buttons to the form.

However I can't access the method: axWmp.Ctlcontrols.play();

'WMPLib.IWMPControls' does not contain a definition for 'play' and no extension method 'play' accepting a first argument of type 'WMPLib.IWMPControls' could be found (are you missing a using directive or an assembly reference?)'

This would not happen if I add Windows Media Player under Windows Form .NET 2.0 Application. Is there any way to access开发者_运维技巧 the .play() and .stop() functions?


You need to add a COM reference to Windows Media Player wmp.dll in your main project.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜