Press "Enter" to skip to content

Convert PDF Documents to Word Documents with Microsoft Power Automate

Ever needed to generate a new Word document from a PDF document? Or a co-worker has deleted / lost the original source Word document? Or you receive external PDF documents you’d like to augment but don’t want to deploy PDF editing software across your estate?

Our new ‘Convert PDF to Word‘ action for Microsoft Power Automate and Logic Apps enables you to build on-demand or automated solutions for these types of requirements.

Scenario

Business users require an on-demand solution for converting PDF documents held within a SharePoint library to editable Microsoft Word (docx) documents.

Guide

1. Navigate to the target SharePoint library and click ‘Flow‘ > ‘Create a flow

2. Click ‘Show more

3. Click ‘Complete a custom action for the selected file

4. The initial flow will be automatically configured. Rename the flow to something relevant such as ‘Convert PDF to Word

5. Add a ‘Get file content‘ SharePoint action

5.a. Site Address: Set as per the values of the ‘Site Address‘ fields of the existing SharePoint actions.

5.b File Identifier: Select the ‘File Identifier‘ property from the ‘Get file properties‘ action

6. Add a ‘Convert PDF to Word‘ Encodian action

6.a. Filename: Select the ‘File name with extension‘ property from the ‘Get file properties‘ action

NOTE: The Encodian connector will automatically change the file extension of the filename entered in the ‘Filename‘ field to ‘docx

6.b. File Content: Select the ‘File content‘ property from the ‘ Get file content‘ action:

7. Add a ‘Create file‘ SharePoint action

7.a. Site Address: Set as per the values of the ‘Site Address‘ fields of the existing SharePoint actions.

7.b. Folder Path: Select the ‘Folder Path‘ property from the ‘Get file properties‘ SharePoint action

7.c. File Name: Select the ‘Filename‘ property from the ‘Convert PDF to Word‘ Encodian action

7.d. File Content: Select the ‘File Content‘ property from the ‘Convert PDF to Word‘ Encodian action

OPTIONAL – The following steps will add a parallel branch which will send an email to the user if a conversion request did not complete, which could occur when the user selected an incorrect source document (i.e. not a PDF document).

8. Add a parallel branch above the ‘Create file‘ action

9. Add a ‘Send an email (V2)‘ action to the new branch

10. Select the ‘Send an email (V2)‘ action, click ‘‘,  then select  ‘Configure run after

11. Select the following run after settings: ‘has failed‘, ‘has timed out‘ then click ‘Done

12. Select the ‘Send an email (V2)‘ action.

12.a. To: Select the ‘User email‘ property from the ‘For a selected file‘ SharePoint action

12.b. Configure the ‘Subject‘ and ‘Body‘ fields as required

13. Underneath the ‘Create file’ SharePoint action  add a ‘Send an email (V2)‘ action

13.a. To: Select the ‘User email‘ property from the ‘For a selected file‘ SharePoint action

13.b. Configure the ‘Subject‘ and ‘Body‘ fields as required

14. The completed flow should follow this construct:

15. Click ‘Save

16. Go back to the SharePoint library, select a PDF document, click ‘Flow‘ then ‘Convert PDF to Word

17. Click ‘Continue

NOTE: As the Encodian connector uses API Key authentication you will be prompted to provide these details. To work around the need to create an Encodian connection a custom connector which points to the Encodian REST endpoint can be created. The resulting connection can then be shared with required users, thus negating the need to create new connections. Please email support@encodian.com for more details.

18. Click ‘Create

19. Configure the new connection and click ‘Create

19.a. Connection Name: Enter a descriptive connection name

19.b. API Key: Enter your Encodian API Key which can be obtained here or request a new Encodian subscription here

20. Click ‘Continue

21. Click ‘Run flow

22. Validate the flow has executed as required by checking the SharePoint library and received email.

23. Verify the new document opens and can be edited within Microsoft Word

Post completion of the initial configuration re-executing the flow is a seamless and simple process for end users.

We hope you’ve found this guide useful, and as ever, please share any feedback or comments –  all are welcome!

Be First to Comment

Leave a Reply

Your email address will not be published. Required fields are marked *