【发布时间】:2012-07-26 20:03:02
【问题描述】:
我正在寻找一种使用 Delphi 通过自动化保护 powerpoint 演示文稿的方法。
在 Word 中,我可以发出以下命令:
If (WordDocument.ProtectionType = wdNoProtection)
Then WordDocument.Protect (3, VarTrue, VarProtectPass);
在 Excel 中,我可以发出以下命令:
{ If the file was NOT protected, then protect it }
For SheetIndex := 1 To ExcelWorkbook.Sheets.Count Do Begin
VarSheet := SheetIndex;
{ Connect to the work sheet }
ExcelWorksheet.ConnectTo (ExcelWorkbook.Worksheets.Item [VarSheet] As _Worksheet);
ExcelWorksheet.Protect ()...
问题是我找不到使用 OfficeXP.pas 组件的方法。我们在各种系统上运行 Office 2010。有什么想法吗?
我需要用演示文稿打开 powerpoint, 1) 对于 MenuItem1,禁止用户进行任何编辑。此外,不允许他们将其重新保存到其他地方。 2) 对于 MenuItem2,允许用户编辑演示文稿。
【问题讨论】:
-
您希望自动化的 PowerPoint 操作是什么?
标签: delphi user-interface automation ms-office powerpoint