我希望能够通过按 Windows 窗体中的按钮来浏览 Powerpoint 演示文稿。这是我从 http://bytes.com/topic/c-sharp/answers/272940-open-powerpoint-presentation-c-window-form 中找到的一些代码打开 Powerpoint 演示文稿幻灯片放映:
Microsoft.Office.Interop.PowerPoint.Application oPPT;
Microsoft.Office.Interop.PowerPoint.Presentations objPresSet;
Microsoft.Office.Interop.PowerPoint.Presentation objPres;
//the location of your powerpoint presentation
string strPres = @"filepath";
//Create an instance of PowerPoint.
oPPT = new Microsoft.Office.Interop.PowerPoint.ApplicationClass();
// Show PowerPoint to the user.
oPPT.Visible = Microsoft.Office.Core.MsoTriState.msoTrue;
objPresSet = oPPT.Presentations;
//open the presentation
objPres = objPresSet.Open(strPres, MsoTriState.msoFalse,
MsoTriState.msoTrue, MsoTriState.msoTrue);
objPres.SlideShowSettings.Run();
但是,我还没有找到任何可以推进幻灯片的方法。有什么想法吗?
(我真正想做的是使用 WiiRemote 来推进幻灯片,用于学生项目)。
最佳答案
以编程方式推进的方法是“SlideShowWindow.View.Next”。您还可以使用“SlideShowWindow.View.Previous”向后移动。
关于C# - 以编程方式推进 Powerpoint 幻灯片放映的方式?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/1463358/