在 powerpoint 2010 中引入了一种新的视图类型,称为“阅读视图”。我正在尝试将其应用于演示文稿,但办公室互操作的 PpViewType 枚举不包含任何将演示文稿视图修改为“阅读视图”的成员。任何人都可以帮助我是否已在其他地方定义或者我如何以编程方式更改为阅读视图?
PowerPoint.Application oPPT = new PowerPoint.Application();
//Add New Presentation
PowerPoint.Presentations oPresSet = oPPT.Presentations;
PowerPoint.Presentation oPres = oPresSet.Add(Office.MsoTriState.msoTrue);
//Add Slides to the Presentation
PowerPoint.Slides oSlides = oPres.Slides;
PowerPoint.Slide oSlide = oSlides.Add(1, PowerPoint.PpSlideLayout.ppLayoutTitleOnly);
oSlide.Shapes[1].TextFrame.TextRange.Text ="sample text";
//Changing View Type
oPres.Application.ActiveWindow.ViewType = PowerPoint.PpViewType.ppViewNotesPage;