How to create a word document from a template in Power Automate

In this Power Automate tutorial, we will discuss Microsoft flow to create a word document from a template. We will see an example, how to create a word document from a template in Power Automate. And also we will discuss the below points:

  • Microsoft flow create word document from template
  • Power Automate create pdf from word template
  • Power Automate create word document from SharePoint list

Microsoft flow create word document from template

Here we will see how to create a Word document From a template using Power Automate

First, we will create an invitation using a Word template, in this template we will change the Person Name dynamically.

Steps to create a Word document from a template using Microsoft Flow.

Step 1: Create a Word Template

I have already created a word template of invitation like the below image, by using Developer tools in MS Word desktop app. Here Person name will be updated automatically by MS Flow.

For example, if we give input the person name as Alex, so Name of the person, will change to Alex.

microsoft flow create word document from template
Microsoft flow create word document from template

Then save that template on the desktop as a Word template i.e. in .dotx. And then in the MS Word app open that template, and save it word document as .docx file.

Once you save it as a word document, then upload that document to the SharePoint library.

Power automate create word document from template
Power automate create word document from template

Once you upload the template to the SharePoint library, now we will forward it to create a flow.

Step 2: Create a Flow

To create a Flow, Login to Power automate and then click on Create icon select Instant cloud Flow.

How Power automate create word document from template
How Power automate create word document from template

Next, provide the flow name, select Manually triggered flow, then click on Create.

How Microsoft Flow create word document from template
How Microsoft Flow create word document from template

Step 3: Manually triggered Flow

Now expand the Manually triggered flow action, then click on Add an input, and select As Text option. Then add the Input as Person Name.

MS flow create word document from template
MS flow create word document from template

Step 4: Populate a Microsoft Word Document

In this step, we will read the Microsoft Word template to fill the template fields (Person Name) with selected dynamic values to generate a word document. So, click on the Next step and select the Populate a Microsoft Word Document, and also to use this action you need a premium license.

Then provide the Location, Document Library, Files, and in Person Name select the Person Name from the dynamic content.

create word document from template in MS Flow
create word document from template in MS Flow

Now we will create a word document from the template, so click on the Next step and select Create File. Then provide the site address, folder path, file name, and File content from the dynamic content.

create word document from template in power automate
create word document from template in power automate

Now click on and run the flow Manually, and it will ask for the Person Name, like the below screenshot.

create word document from template using MS Flow
create word document from template using MS Flow

Now in SharePoint library Power automate created a word document from the template.

create word document from template using Microsoft Flow
create word document from template using Microsoft Flow

Open the Word document, you can see the person name is changed to Christen in the Word document invitation.

How to create word document from template using Microsoft Flow
How to create word document from template using Microsoft Flow

This is an example of how to create a word document from a template in Microsoft flow or Power Automate.

Read Power Automate Create File

Power Automate create pdf from word template

Here we will see how to create pdf from a word template using Microsoft Flow.

Now we will use the above word template to create a flow to convert it into pdf.

microsoft flow create word document from template
Microsoft flow create word document from template

Once the template is ready, we will create a flowing Microsoft Flow.

Step 1: Create an Input

In Power Automate select the Manually triggered flow. Then expand this action and click on Add an input and select text, then in input provide the person Name.

Power automate create word document from template
Power automate create word document from template

Step 2: Populate a Microsoft Word template

In this step we will fill the field in the Microsoft template, so click on the Next step and select the Populate a Microsoft word template action. Then provide the Location, Document Library, select the word File, and in person Name select person from the dynamic content.

MS flow create word document from template
MS flow create word document from template

Step 3: Create File

Now we will create file, so click on the Next step and select Create file action, then provide the site address, folder path, File name and File content.

MS Flow create pdf from word template
MS Flow create pdf from word template

Step 4: Convert the word document to pdf

In this step we will convert the word document to pdf, so click on the Next step and select the Convert word document to pdf action and this action need a premium license, so click on the Next step and then provide the Location, Document Library, and then in File select the Name from the dynamic content.

create pdf from word template using MS-Flow
create pdf from word template using MS-Flow

Step 5: Create pdf file

Now we will create a file for the pdf file, so click on the Next step and select Create file action, then provide site address, folder path, file name with pdf expression, and file content.

create pdf from word template using Microsoft Flow
create pdf from word template using Microsoft Flow

Step 6: Delete word file

Now we will delete the word document file, so click on the Next step and select the Delete File action, then provide the site address, and File identifier.

create pdf from word template using Power Automate
create pdf from word template using Power Automate

Now click on Save and run the Flow, and input the person name. Then you can see the file converted with pdf.

How to create pdf from word template using Power Automate
How to create pdf from word template using Power Automate

This is an example of Power Automate create pdf from word template

Read Power Automate Replace

Power Automate create word document from SharePoint list

Here we will see how to create a word document from a SharePoint list using Power Automate.

We will generate an offer letter word document for every new person joining the organization using the preferred values from a SharePoint list.

I have created a SharePoint list called offer letter data, so when a user adds a new person as an entry in the SharePoint list, it will automatically add the value to the properties in a word document.

Steps for Power Automate create word document from the SharePoint list.

Step 1: Create a Word Document

I have created a word document template in the desktop word app, with the three properties.

  • Employee Name
  • Date
  • Salary
Power Automate create word document from SharePoint list
Power Automate create word document from SharePoint list

Once you have created a template save the template as .dotx and then open that template and save it as .docx document in the desktop.

After saving the document as .docx in desktop, upload the file to the SharePoint document library.

Power Automate create word document from SharePoint list
Power Automate create word document from SharePoint list

Step 2: Create SharePoint list

I have created a SharePoint list called offer letter, with the 4 columns and column type.

ColumnColumn type
TitleSingle line of text
Date of joiningDate and time
Employee NameSingle line of text
SalarySingle line of text
Power Automate create word document from SharePoint list
Microsoft flow create word document from SharePoint list
Microsoft flow create word document from SharePoint list

Once the SharePoint list and word template is created, we will create a flow in Power Automate.

Step 3: Create a flow

To create a flow Login to Power Automate, then click on create and select Automated cloud flow.

MS flow create word document from SharePoint list
MS flow create word document from SharePoint list

Then provide the flow name, and select the trigger ‘When an item is created‘ action.

how Microsoft flow create word document from SharePoint list
how Microsoft flow create word document from SharePoint list

Step 4: When a new item is created

In this step provide the site address and list name of the list you have created in SharePoint.

how MS flow create word document from SharePoint list
how MS flow create word document from SharePoint list

Step 5: Populate a Microsoft word template

In this step, we will read the Microsoft word document, and fill the field in the Microsoft word template from the SharePoint list data.

So click on the Next step and select Populate a Microsoft word template action. Then provide the Location, Document library, and File. Then map the field of word template with SharePoint list field data.

how Power automate create word document from SharePoint list
how Power automate create word document from SharePoint list

Step 6: Create File

Now we will create a file in word document, so click on the Next step and select Create file action. Then provide the site address, folder path, file name and file content.

how to create word document from SharePoint list using Power automate
how to create word document from SharePoint list using Power automate

Once the flow is ready, we will run the Flow manually.

Step 7: Run the Flow

Now click on Save and to run the flow create an item in the SharePoint list like below.

how to create word document from SharePoint list using MS Flow
how to create word document from SharePoint list using MS Flow

Now you can see the Flow ran successfully and also you can see the word document is created.

how to create word document from SharePoint list using Microsoft Flow
how to create word document from SharePoint list using Microsoft Flow

And you can see the Properties are updated in Word template.

how to create word document from SharePoint list using Power Automate
how to create word document from SharePoint list using Power Automate

This is an example of how to create a word document from a SharePoint list in Power Automate.

Related Power Automate tutorials:

In this Power Automate tutorial, we discuss Microsoft flow create a word document from a template. And also we discuss the below points:

  • Power Automate create pdf from word template
  • Power Automate create word document from SharePoint list
  • Can you provide the steps you used at the beginning to “create a word template of invitation…by using Developer tools in MS Word desktop app”? What developer tool allows you to add a custom field?

  • >