Merge PowerPoint files using Power Automate

In this guide you’ll learn how to combine and merge multiple PowerPoint files into a single PowerPoint document using Power Automate.

For this specific example we build a Flow that will Loop through all the documents once a day in a OneDrive for Business Folder, merge them, and then create a merged PowerPoint document in a different location of our choice.

It’s important to note that in this example we are combining documents in OneDrive but you can easily merge multiple documents and save them to another destination like Dropbox, Google Drive, SharePoint, or any platform supported by Power Automate.

Prerequisites

Before we begin. please make sure the following prerequisites are in place:

  1. An Office 365 subscription with Flow and OneDrive for Business support.
  2. Muhimbi PDF Converter for Power Automate full or trial subscription.
  3. Appropriate privileges to create Flows.
  4. Working knowledge of Microsoft Flow.

Merging MS PowerPoint using Power Automate (Flow Array Technique)

From a high level, the Flow will look like this:

merge ppt using power automate

  1. Create a Scheduled Cloud Flow and then enter a suitable Flow Name, with a suitable Start Date and Start Time with a recurrence set to every day.

create flow

  1. Insert ‘Initialize variable’ Flow action to store the Merged Contents. Give this action a suitable name and set the fields as follows: Type: ‘String’ Initial value: Null

variable flow

  1. Insert ‘Initialize variable’ Flow action to store the Merged Count. Type: “Integer” Initial Value: Null

merged count

  1. Add the OneDrive for Business ‘List Files in folder’ Action on the Folder library which contains all the files that need to be Merged.

list files in folder

  1. Insert the ‘Apply to Each Loop’ and add the Output(value) of ‘List Files in folder’ action.

apply to each loop

  1. Insert the ‘Add a condition’ action. Insert IsFolder is the Output of “List Files in folder” and you need to set it to “False”.

add a condition path

  1. If the step above, evaluates to True, add the action ‘Get file content using path’

File Path: Path variable which is the output of ‘List Files in folder’.

folder path

  1. Insert the ‘Add a condition’ action. Insert Merge Count is the Output of ‘Initialize variable – Merge Count’ and you need to set it to “0”.

file path

  1. If the step above, evaluates to True, add the Muhimbi ‘Convert Document Action’ The Action has two parameters:

Source File Name: ‘Name’ is the output of ‘List Files in folder’. Source File Content: ‘Body’ is the output of ‘Get file Content using Path’.

file name and content

  1. Insert the OneDrive for Business ‘Create file’ action after the ‘Convert document’ action. The action has three main parameters

Folder Path: The Path of your destination Folder. File name: You can create a variable for File name if needed. We have hardcoded it to ‘MergedFile.pptx’. File Content: Processed File Content is the output of ‘Convert Document’ action.

convert document action

  1. Now, if the step 8 above, evaluates to False i.e. Merge Count is now not equal to 0, then add the action ‘Get file Content using Path’.

File Path : Enter the same path as in step 10.

get file content using path

  1. Add the Muhimbi ‘Merge documents’ action. It has the following two main parameters

Source File name -1: You can hardcode the File Name ‘MergedFile.pptx’ This file name should be the same as in step 10 and 11. Source File Content -1: File Content is the output of ‘Get file Content using Path 2’ as in step 11. Source File name -2: Name is the output of ‘List Files in folder’. Source File Content -2: File Content is the output of ‘Get file Content using Path’ in step 8.

merge documents

  1. Add the OneDrive for Business ‘Create file’ action, under step 12. The Action has three main parameters:

Folder Path: The path of your destination folder. File name: We have hardcoded it to ‘MergedFile.pptx’. File Content: Processed File Content is the output of ‘Merge Document’ action.

create file action

  1. Outside ‘Condition 2’ action, add a ‘Set variable’ action. The action has two main parameters:

Name: Select the ‘Merged Count’ variable initialized in step 2. Value: Set the Value to 1.

condition action

You can test this workflow by setting the recurrence “Recurrence” Frequency to ‘Minute’. This will trigger the Flow after a minute and merge multiple documents in the source folder to a single MS PowerPointdocument in the target location.

Additional Resources

Have a Question?
We’re Always Happy to Help.

© Muhimbi Ltd. 2008 - 2024
This website uses cookies to ensure you get the best experience. Learn more