Introduction

Nowadays, the buzz word in the market is MS Flow. I would say that without MS Flow, SharePoint Online is incomplete. When we talk about SharePoint Online, we must talk about other related technology like MS Flow, PowerApps, SPFx, Teams, etc. These all go side by side. As Microsoft is focusing more on SharePoint Online, the on-premise version is not what they are recommending to use, not even the SharePoint designer workflow. In this context, we could say that MS Flow is a recommended/alternate approach of the modern way of developing a workflow, instead of designer workflow.

There are plenty of advantages of MS Flow – I am not going in-depth for this as the purpose of this article is to create HTML in MS Flow, so my focus would be on how we can make use of Create HTML action inside MS Flow.

Use cases of HTML table in MS Flow

There are many use cases in our SharePoint application. I’ll briefly discuss a few – let’s say your boss has assigned tasks to the team members and at the end of the day, he/she wants to get the consolidated task status auto-emailed. Then, the MS Flow with “Create HTML” is the right choice

Actual Implementation – step by step walk through

I assume that you know how to create that list with custom columns, so I am skipping the list creation step, hence here is my already created Communication Site list.

Using the MS Flow, I will send these list data to the email in the form of HTML. So let’s start — how can we do this?

From your “Communication Site” list page, click on the “Flow” dropdown list and then click the “Create a flow” button, as mentioned below.

 

 

 

Click on the “Create a Flow” its will open the dropdown list and Click on  “Show more” Option.

 

 

Then, we’ll land on the below page.

 

 

 

 

 

 

 

 

 

 

 

“Site Address” and “List Name” pre-populated – make sure these are correct.

 

 

 

 

 

At this moment lets name this flow as “Create and Send HTML Table to Email” then click on “+Next step” button

 

 

 

 

 

Then search with “SharePoint” and select “Get Items” action as mentioned below

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Select the “Site Address” and “List Name” as mentioned below.

Add data operation “Compose” action: search for “Compose” text and select the “Data Operations” as below,From the next screen, select the “Select Data Operations” action

 

 

 

 

 

 

 

 

 

 

 

We will get the empty “From” and “Map” in “Select” operation action – you need to click on the from box and need to double click on the “value” (from Dynamic content) tab

 

 

 

 

create a meaningful mapping name corresponding to your column, then click on second box (add dynamic content), under dynamic content tab in search box type your column name which you want to map , then select your column under “Get Items” section.

Next Click On “New Step” and Select “Create HTML Table” action like below – search with “Create” text then click on “Create HTML Table” action

 

 

 

 

 

 

 

 

Now we can see “Create HTML Table” action as below,

Next Click On “New Step”,and Search for the outlook and select the “Send An email (V2)”

 

 

 

 

 

 

 

 

 

 

Enter the mandatory parameters as below for the email action.

 

 

 

 

 

 

 

From the next screen, select the first radio button and click on “Test” button as below.

 

 

 

 

 

 

 

 

 

 

 

Wait for a few seconds – you will get the below screen

 

 

 

 

As the above highlighted message says – add a new item to the SharePoint “Communicate Site” list to trigger the flow.

 

 

 

 

 

 

Come to your flow screen(tab) – if everything goes fine you should see the below flow ran a successful message.

 

 

 

 

 

 

 

 

Open your outlook office 365 mail box

 

 

 

 

 

Here you can see an email has come with all customer details in the html tabular format in the email body – we are done with our basic purpose of this article but the html table in the email body does not look nice, however, this is the default behavior. Now we’ll format it a little to look better.

How to format the HTML Table in MS Flow

Click Here

For any Help or Queries Contact us on info@crmonce.com or +918096556344