Blog Post

Create a Word document from a SharePoint list in Power Automate

Marija Trpkovic
Illustration: Create a Word document from a SharePoint list in Power Automate

Nutrient’s Document Converter for Power Automate and REST API has a variety of actions that can speed up your document management workflows. One of them is the ability to merge a SharePoint list to a Word document using Power Automate. This Power Automate flow involves getting items from your SharePoint list with a SharePoint action, composing an HTML file, and using Nutrient’s action to convert HTML to DOCX.

How to populate a Word document from a SharePoint list

Populate a Word document from a SharePoint list

  1. Create an automated cloud flow and choose the When an item is created or modified trigger.

  2. Specify your site address and list name.

  3. Add the Get item SharePoint action. In addition to the Site Address and List Name fields, fill in the Id field with an ID from the list of dynamic content.

  4. Create HTML code and modify the inputs in the HTML form. You can take an HTML example like this and change it according to your input values:

<!DOCTYPE html>
<html>
<body>

<h1>Personal details</h1>

<p>Name:</p>

</body>
</html>
  1. Add another action by typing Compose and choosing the Data Operation action.

Generate a Word document from a SharePoint list

  1. Copy and paste the HTML code, and then use dynamic content on the right side to add values that are present in your list.

  2. Add the Nutrient Convert document action. In the Source file name field, add the GivenName value from the dynamic content on the right and enter it with the .html extension. In the Source file content field, choose Outputs. In the Output format field, choose DOCX.

Power Automate flow to convert a SharePoint list

  1. The last step is to choose the Create file action. Fill in all the fields and press Save. The File Name field will be Base file name.docx, as shown in the image below. The File Content field will say Processed file content.

Create a Word document from a SharePoint list

  1. The next time you add a new item to your SharePoint list or modify an existing one, this list will be converted into Word and placed in the designated folder.

Convert a SharePoint list

In addition to converting SharePoint lists to Word, you can follow the same steps and change the output of a document, which enables you to convert SharePoint lists to XLS, CSV, PNG, JPG, and more.

Nutrient’s Document Converter for Power Automate and REST API has more than 25 actions available — including splitting, merging, extracting form data, filling out forms, and securing and watermarking documents — that will automate your document management workflow.

Want to see it in action? Contact us to schedule a demo!

Author
Marija Trpkovic Product Marketing Manager

Marija is a product marketing manager who likes to launch new products and features and target the right people with them. Outside of work, she likes spending time outdoors with her family and dogs.

Explore related topics

Share post
Free trial Ready to get started?
Free trial