Em,there is a way to get it. First you need add the mediaplayer class (or other media player class),here is a example used MediaPlayer:add reference click panel of COM at the windows of Add Reference you can find Microsoft Media Player here, select it, ok, then you can see a new reference named WMPLib at your Solution Explorer. now take attention to Code Editor and add this code to your function://define a new WindowsMediaPlayerClass WMPLib.WindowsMediaPlayerClass p = new WMPLib.WindowsMediaPlayerClass(); //add a new media to your mediapalyer p.add("C:\\yourmedia"); //now play it p.play(); //the rate of media p.rate; //add other code here //if you want do other thing please turn to the introduction of MediaPlayer
click panel of COM at the windows of Add Reference
you can find Microsoft Media Player here, select it, ok, then you can see a new reference named WMPLib at your Solution Explorer.
now take attention to Code Editor and add this code to your function://define a new WindowsMediaPlayerClass
WMPLib.WindowsMediaPlayerClass p = new WMPLib.WindowsMediaPlayerClass();
//add a new media to your mediapalyer
p.add("C:\\yourmedia");
//now play it
p.play();
//the rate of media
p.rate;
//add other code here
//if you want do other thing please turn to the introduction of MediaPlayer