WPS 基础接口 > 演示 API 参考 > ActionSettings > 属性 > ActionSettings.Application 属性
返回一个 Application 对象,该对象表示指定对象的创建者。

语法

表达式.Application

表达式   一个代表 ActionSettings 对象的变量。

返回值
Application

示例

以下示例中,一个 Presentation 对象被传递至某过程。此过程在演示文稿中添加一张幻灯片,然后将该演示文稿保存在运行 WPP 的文件夹中。

示例代码
function AddAndSave(pptPres) {
    pptPres.Slides.Add(1, 1)
    pptPres.SaveAs(pptPres.Application.Path + "\\Added Slide")
}

以下示例显示在当前演示文稿的第一张幻灯片上创建每个链接的 OLE 对象的应用程序的名称。

示例代码
for(let i=1;i <= ActivePresentation.Slides.Item(1).Shapes.Count;i++) {
    if(ActivePresentation.Slides.Item(1).Shapes.Item(i).Type == msoLinkedOLEObject) {
        MsgBox(ActivePresentation.Slides.Item(1).Shapes.Item(i).OLEFormat.Application.Name)
    }
}


请参阅