public void PptAction(PptDetails pptDetails) { pptDetailsMain = pptDetails; DodoMediaPlayer.Stop(); this.Hide(); if (pptDetails != null) { try { //Create a new presentation based on a template. objApp = new powerpointinterop.Application(); // objApp.SlideShowBegin += new Microsoft.Office.Interop.PowerPoint.EApplication_SlideShowBeginEventHandler(powerpnt_SlideShowBegin); objApp.SlideShowEnd += new Microsoft.Office.Interop.PowerPoint.EApplication_SlideShowEndEventHandler(powerpnt_SlideShowEnd); //objApp.SlideShowNextSlide += new Microsoft.Office.Interop.PowerPoint.EApplication_SlideShowNextSlideEventHandler(powerpnt_SlideShowNextSlide); objApp.Visible = MsoTriState.msoTrue; objPresSet = objApp.Presentations; string pptName = pptDetails.Name; string pptPath = System.IO.Path.Combine(Mocker.debugPath, "Ppts", pptName); objPres = objPresSet.Open(pptPath, MsoTriState.msoTrue, MsoTriState.msoTrue, MsoTriState.msoTrue); objSlides = objPres.Slides; objSSS = objPres.SlideShowSettings; objSSS.Run(); } catch (Exception) { } } else { MessageBox.Show("Media Not Found"); } }
public void PauseVideo() { if (DodoMediaPlayer.CanPause) { DodoMediaPlayer.Pause(); } }
public void StopVideo() { if (DodoMediaPlayer.Source != null) { DodoMediaPlayer.Stop(); } }
public void PlayAfterPauseVideo() { if (DodoMediaPlayer.Source != null && DodoMediaPlayer.Source.OriginalString != string.Empty) { DodoMediaPlayer.Play(); } }
public void PositionBackVideo() { if (DodoMediaPlayer.Source != null) { DodoMediaPlayer.Position = DodoMediaPlayer.Position - new TimeSpan(0, 0, 20); DodoMediaPlayer.Play(); } }
public void PlayVideo(VideoDetails videoDetails) { if (videoDetails != null) { videoDetailsMain = videoDetails; string videoPath = System.IO.Path.Combine(Mocker.debugPath, "Videos", videoDetails.Name); DodoMediaPlayer.Source = new Uri(videoPath); this.Show(); DodoMediaPlayer.Play(); } }