You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/powerpoint/insert-slides-into-presentation.md
+6-6Lines changed: 6 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,11 +1,11 @@
1
1
---
2
-
title: Insert slides in a PowerPoint presentation
2
+
title: Insert slides from another PowerPoint presentation
3
3
description: Learn how to insert slides from one presentation into another.
4
-
ms.date: 03/07/2021
4
+
ms.date: 11/07/2025
5
5
ms.localizationpriority: medium
6
6
---
7
7
8
-
# Insert slides in a PowerPoint presentation
8
+
# Insert slides from another PowerPoint presentation
9
9
10
10
A PowerPoint add-in can insert slides from one presentation into the current presentation by using PowerPoint's application-specific JavaScript library. You can control whether the inserted slides keep the formatting of the source presentation or the formatting of the target presentation.
11
11
@@ -38,13 +38,13 @@ There are many ways to convert a file to Base64. Which programming language and
38
38
> [!NOTE]
39
39
> There are many other ways to get a PowerPoint file. For example, if the file is stored on OneDrive or SharePoint, you can use Microsoft Graph to download it. For more information, see [Working with files in Microsoft Graph](/graph/api/resources/onedrive) and [Access Files with Microsoft Graph](/training/modules/msgraph-access-file-data/).
40
40
41
-
2. Add the following code to the add-in's JavaScript to assign a function to the input control's `change` event. (You create the `storeFileAsBase64` function in the next step.)
41
+
1. Add the following code to the add-in's JavaScript to assign a function to the input control's `change` event. (You create the `storeFileAsBase64` function in the next step.)
42
42
43
43
```javascript
44
44
$("#file").on("change", storeFileAsBase64);
45
45
```
46
46
47
-
3. Add the following code. Note the following about this code.
47
+
1. Add the following code. Note the following about this code.
48
48
49
49
- The `reader.readAsDataURL` method converts the file to Base64 and stores it in the `reader.result` property. When the method completes, it triggers the `onload` event handler.
50
50
- The `onload` event handler trims metadata off of the encoded file and stores the encoded string in a global variable.
@@ -165,6 +165,6 @@ async function insertAfterSelectedSlide() {
165
165
> [!NOTE]
166
166
> The slides will be inserted in the same relative order in which they appear in the source presentation, regardless of the order in which they appear in the array.
167
167
168
-
There is no practical way that users can discover the ID or creation ID of a slide in the source presentation. For this reason, you can really only use the `sourceSlideIds` property when either you know the source IDs at coding time or your add-in can retrieve them at runtime from some data source. Because users cannot be expected to memorize slide IDs, you also need a way to enable the user to select slides, perhaps by title or by an image, and then correlate each title or image with the slide's ID.
168
+
There's no practical way that users can discover the ID or creation IDof a slide in the source presentation. Forthis reason, you can really only use the `sourceSlideIds` property when either you know the source IDs at coding time or your add-in can retrieve them at runtime from some data source. Because users cannot be expected to memorize slide IDs, you also need a way to enable the user to select slides, perhaps by title or by an image, and then correlate each title or image with the slide's ID.
169
169
170
170
Accordingly, the `sourceSlideIds` property is primarily used in presentation template scenarios: The add-in is designed to work with a specific set of presentations that serve as pools of slides that can be inserted. In such a scenario, either you or the customer must create and maintain a data source that correlates a selection criterion (such as titles or images) with slide IDs or slide creation IDs that has been constructed from the set of possible source presentations.
Copy file name to clipboardExpand all lines: docs/powerpoint/use-document-themes-in-your-powerpoint-add-ins.md
+14-14Lines changed: 14 additions & 14 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,27 +1,27 @@
1
1
---
2
-
title: Use document themes in your PowerPoint add-ins
2
+
title: Use Office document themes in your PowerPoint add-ins
3
3
description: Learn how to visually coordinate themes, such as fonts and colors, to apply to PowerPoint presentations.
4
-
ms.date: 06/18/2024
4
+
ms.date: 11/07/2025
5
5
ms.localizationpriority: medium
6
6
---
7
7
8
-
# Use document themes in your PowerPoint add-ins
8
+
# Use Office document themes in your PowerPoint add-ins
9
9
10
10
An [Office theme](https://support.microsoft.com/office/83e68627-2c17-454a-9fd8-62deb81951a6) consists, in part, of a visually coordinated set of fonts and colors that you can apply to presentations, documents, worksheets, and emails. To apply or customize the theme of a presentation in PowerPoint, you use the **Themes** and **Variants** groups on **Design** tab of the ribbon. PowerPoint assigns a new blank presentation with the default **Office Theme**, but you can choose other themes available on the **Design** tab, download additional themes from Office.com, or create and customize your own theme.
11
11
12
12
Using **OfficeThemes.css**, design add-ins that are coordinated with PowerPoint in two ways.
13
13
14
-
-**In content add-ins for PowerPoint**. Use the document theme classes of **OfficeThemes.css** to specify fonts and colors that match the theme of the presentation your content add-in is inserted into - and those fonts and colors will dynamically update if a user changes or customizes the presentation's theme.
14
+
-**In content add-ins for PowerPoint**. Use the document theme classes of **OfficeThemes.css** to specify fonts and colors that match the theme of the presentation your content add-in is inserted into. Those fonts and colors will dynamically update if a user changes or customizes the presentation's theme.
15
15
16
-
-**In task pane add-ins for PowerPoint**. Use the Office UI theme classes of **OfficeThemes.css** to specify the same fonts and background colors used in the UI so that your task pane add-ins will match the colors of built-in task panes - and those colors will dynamically update if a user changes the Office UI theme.
16
+
-**In task pane add-ins for PowerPoint**. Use the Office UI theme classes of **OfficeThemes.css** to specify the same fonts and background colors used in the UI so that your task pane add-ins will match the colors of built-in task panes. Those colors will dynamically update if a user changes the Office UI theme.
17
17
18
18
## Document theme colors
19
19
20
20
Every Office document theme defines 12 colors. Ten of these colors are available when you set font, background, and other color settings in a presentation with the color picker.
To view or customize the full set of 12 theme colors in PowerPoint, in the **Variants** group on the **Design** tab, click the **More**drop-down - then select **Colors** > **Customize Colors** to display the **Create New Theme Colors** dialog box.
24
+
To view or customize the full set of 12 theme colors in PowerPoint, in the **Variants** group on the **Design** tab, click the **More**dropdown list then select **Colors** > **Customize Colors** to display the **Create New Theme Colors** dialog box.
25
25
26
26

27
27
@@ -33,15 +33,15 @@ Every Office document theme also defines two fonts -- one for headings and one f
33
33
34
34

35
35
36
-
To view or customize theme fonts in PowerPoint, in the **Variants** group on the **Design** tab, click the **More**drop-down - then select **Fonts** > **Customize Fonts** to display the **Create New Theme Fonts** dialog box.
36
+
To view or customize theme fonts in PowerPoint, in the **Variants** group on the **Design** tab, click the **More**dropdown list then select **Fonts** > **Customize Fonts** to display the **Create New Theme Fonts** dialog box.
37
37
38
38

39
39
40
40
### Office UI theme fonts and colors
41
41
42
-
Office also lets you choose between several predefined themes that specify some of the colors and fonts used in the UI of all Office applications. To do that, you use the **File** > **Account** > **Office Theme**drop-down (from any Office application).
42
+
Office also lets you choose between several predefined themes that specify some of the colors and fonts used in the UI of all Office applications. To do that, you use the **File** > **Account** > **Office Theme**dropdown list (from any Office application).
**OfficeThemes.css** includes classes that you can use in your task pane add-ins for PowerPoint so they will use these same fonts and colors. This lets you design your task pane add-ins that match the appearance of built-in task panes.
47
47
@@ -54,7 +54,7 @@ Using the **OfficeThemes.css** file with your content add-ins for PowerPoint let
54
54
Use the following steps to add and reference the **OfficeThemes.css** file to your add-in project.
55
55
56
56
> [!NOTE]
57
-
> The steps in this procedure only apply to Visual Studio 2015. If you are using Visual Studio 2019, the **OfficeThemes.css** file is created automatically for any new PowerPoint add-in projects that you create.
57
+
> The steps in this procedure only apply to Visual Studio 2015. If you're using Visual Studio 2019, the **OfficeThemes.css** file is created automatically for any new PowerPoint add-in projects that you create.
58
58
59
59
1. In **Solution Explorer**, right-click (or select and hold) the **Content** folder in the _**project_name**_**Web** project, choose **Add**, and then select **Style Sheet**.
60
60
@@ -123,7 +123,7 @@ Use the following steps to add and reference the **OfficeThemes.css** file to yo
1. If you are using a tool other than Visual Studio to create your add-in, copy the CSS code from the previous step into atext file. Then, save the file as **OfficeThemes.css**.
126
+
1. If you're using a tool other than Visual Studio to create your add-in, copy the CSS code from the previous step into atext file. Then, save the file as **OfficeThemes.css**.
127
127
128
128
## Reference OfficeThemes.css in your add-in'sHTML pages
129
129
@@ -133,7 +133,7 @@ To use the **OfficeThemes.css** file in your add-in project, add a `<link>` tag
If you are creating your add-in with a tool other than Visual Studio, add a `<link>` tag with the same format specifying a relative path to the copy of **OfficeThemes.css** that will be deployed with your add-in.
154
+
If you're creating your add-in with a tool other than Visual Studio, add a `<link>` tag with the same format specifying a relative path to the copy of **OfficeThemes.css** that will be deployed with your add-in.
155
155
156
156
### Use OfficeThemes.css document theme classes in your content add-in's HTML page
157
157
@@ -182,7 +182,7 @@ If you change the presentation to use another theme or customize the presentatio
182
182
183
183
### Use OfficeThemes.css Office UI theme classes in your task pane add-in's HTML page
184
184
185
-
In addition to the document theme, users can customize the color scheme of the Office user interface for all Office applications using the **File** > **Account** > **Office Theme**drop-down box.
185
+
In addition to the document theme, users can customize the color scheme of the Office user interface for all Office applications using the **File** > **Account** > **Office Theme**dropdown box.
186
186
187
187
The following shows a simple example of HTML in a task pane add-in that uses OfficeTheme.css classes to specify font color and background color. For details about the **OfficeThemes.css** classes that correspond to fonts and colors of the Office UI theme, see [Theme classes for task pane add-ins](#theme-classes-for-task-pane-add-ins).
0 commit comments