Skip to content

Commit 5996b7c

Browse files
ElizabethSamuel-MSFTCopilotdavidchesnut
authored
[PowerPoint] (Overview) Add article about object model (#5213)
* [PowerPoint] (Overview) Add article about object model * Fix typo * Update docs/powerpoint/core-concepts.md Co-authored-by: Copilot <[email protected]> * Apply suggestions from code review Co-authored-by: David Chesnut <[email protected]> --------- Co-authored-by: Copilot <[email protected]> Co-authored-by: David Chesnut <[email protected]>
1 parent 8084d0c commit 5996b7c

File tree

2 files changed

+45
-0
lines changed

2 files changed

+45
-0
lines changed

docs/powerpoint/core-concepts.md

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
---
2+
title: PowerPoint JavaScript object model in Office Add-ins
3+
description: Learn about the key components in the PowerPoint-specific JavaScript object model.
4+
ms.date: 06/18/2025
5+
ms.topic: concept-article
6+
ms.localizationpriority: high
7+
---
8+
9+
# PowerPoint JavaScript object model in Office Add-ins
10+
11+
This article describes concepts that are fundamental to using the [PowerPoint JavaScript API](../reference/overview/powerpoint-add-ins-reference-overview.md) to build add-ins.
12+
13+
## Office.js APIs for PowerPoint
14+
15+
A PowerPoint add-in interacts with objects in PowerPoint by using the Office JavaScript API. This includes two JavaScript object models:
16+
17+
- **PowerPoint JavaScript API**: The [PowerPoint JavaScript API](/javascript/api/powerpoint) provides strongly-typed objects that work with the presentation, slides, tables, shapes, formatting, and more. To learn about the asynchronous nature of the PowerPoint APIs and how they work with the presentation, see [Using the application-specific API model](../develop/application-specific-api-model.md).
18+
19+
- **Common APIs**: The [Common API](/javascript/api/office) give access to features such as UI, dialogs, and client settings that are common across multiple Office applications. To learn more about using the Common API, see [Common JavaScript API object model](../develop/office-javascript-api-object-model.md).
20+
21+
While you'll likely use the PowerPoint JavaScript API to develop the majority of functionality in add-ins that target PowerPoint, you'll also use objects in the Common API. For example:
22+
23+
- [Office.Context](/javascript/api/office/office.context): The `Office.Context` object represents the runtime environment of the add-in and provides access to key objects of the API. It consists of presentation configuration details such as `contentLanguage` and `officeTheme` and also provides information about the add-in's runtime environment such as `host` and `platform`. Additionally, it provides the `requirements.isSetSupported()` method, which you can use to check whether a specified requirement set is supported by the PowerPoint application where the add-in is running.
24+
- [Office.Document](/javascript/api/office/office.document): The `Office.Document` object provides the `getFileAsync()` method, which you can use to download the PowerPoint file where the add-in is running. It also provides the `getActiveViewAsync()` method, which you can use to check whether the presentation is in a "read" or "edit" view. "edit" corresponds to any of the views in which you can edit slides: Normal, Slide Sorter, or Outline View. "read" corresponds to either Slide Show or Reading View.
25+
26+
## PowerPoint-specific object model
27+
28+
To understand the PowerPoint APIs, you must understand how key components of a presentation are related to one another.
29+
30+
- The presentation contains slides and presentation-level entities such as settings and custom XML parts.
31+
- A slide contains content like shapes, text, and tables.
32+
- A layout determines how a slide's content is organized and displayed.
33+
34+
For the full set of objects supported by the PowerPoint JavaScript API, see [PowerPoint JavaScript API](/javascript/api/powerpoint).
35+
36+
## See also
37+
38+
- [PowerPoint JavaScript API overview](../reference/overview/powerpoint-add-ins-reference-overview.md)
39+
- [Build your first PowerPoint add-in](../quickstarts/powerpoint-quickstart-yo.md)
40+
- [PowerPoint add-in tutorial](../tutorials/powerpoint-tutorial-yo.md)
41+
- [PowerPoint JavaScript API reference](/javascript/api/powerpoint)
42+
- [Learn about the Microsoft 365 Developer Program](https://aka.ms/m365devprogram)

docs/toc.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -921,6 +921,9 @@ items:
921921
- name: API reference
922922
href: reference/powerpoint-api-reference.md
923923
displayName: PowerPoint
924+
- name: PowerPoint object model
925+
href: powerpoint/core-concepts.md
926+
displayName: PowerPoint
924927
- name: Add and delete slides
925928
href: powerpoint/add-slides.md
926929
displayName: PowerPoint

0 commit comments

Comments
 (0)