Office中国论坛/Access中国论坛

标题: 【OneKeyTools源代码分享6】删除备注 [打印本页]

作者: 只为设计    时间: 2016-6-16 09:50
标题: 【OneKeyTools源代码分享6】删除备注
本帖最后由 只为设计 于 2016-6-16 12:49 编辑
  1. PowerPoint.Selection sel = app.ActiveWindow.Selection;
  2.             if (sel.Type == PowerPoint.PpSelectionType.ppSelectionSlides)
  3.             {
  4.                 foreach (PowerPoint.Slide item in sel.SlideRange)
  5.                 {
  6.                     for (int i = 1; i <= sel.SlideRange.Count; i++)
  7.                     {
  8.                         int count = item.NotesPage.Count;
  9.                         for (int j = 1; j <= count; j++)
  10.                         {
  11.                             if (item.NotesPage.Shapes.Placeholders[2].TextFrame.TextRange.Text != "")
  12.                             {
  13.                                 item.NotesPage.Shapes.Placeholders[2].TextFrame.TextRange.Text = "";
  14.                             }
  15.                         }
  16.                     }
  17.                 }
  18.             }
  19.             else
  20.             {
  21.                 MessageBox.Show("请先选中要删除备注的幻灯片页面");
  22.             }
复制代码

上一篇:【OneKeyTools源代码分享5】随机旋转    下一篇:OneKeyTools 6 OS开源版发布






欢迎光临 Office中国论坛/Access中国论坛 (http://www.office-cn.net/) Powered by Discuz! X3.3