Trigger a Flow to Convert a document to PDF in SharePoint using Button

In my previous blog post, we created a Flow which can be manually started on a document in a SharePoint Online document Library or List. In this blog, we will create a button using column formatting which will launch a Flow on that item.

Please make sure the following prerequisites are in place:

Step 1: Navigate to and open the Flow that we created in our previous blog post.


Step 2:  Copy the ID from the end of the URL to the clipboard. For example

Step 3: Navigate back to the SharePoint Online document library, click on the column (Button) drop down and click on “Format this Column“.

Format Column

Step 4: Use the GUID that we copied in Step 2 in the JSON below.

“$schema”: ““,
“elmType”: “span”,
“style”: {
“color”: “#0078d7”
“children”: [
“elmType”: “span”,
“attributes”: {
“iconName”: “Flow”
“elmType”: “button”,
“style”: {
“border”: “none”,
“background-color”: “transparent”,
“color”: “#0078d7”,
“cursor”: “pointer”
“txtContent”: “Run Flow”,
“customRowAction”: {
“action”: “executeFlow”,
“actionParams”: “{\”id\”: \”8537634d-2e56-4d98-a494-ed856b68a70a\”}”

Step 5: Copy the JSON below in the Column Formatter and Click on Save, you should see the Button Hyperlink.

SharePoint Column Formatter.jpg


Thanks for reading đź™‚.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s