Embedding HTML code in Power Automate table

Nestor Holynskyj 21 Reputation points
2021-12-21T20:17:27.143+00:00

I have a Power Automate flow that uses the "Create HTML Table" function as one of its steps. One of the fields in the table is a URL address. The latter can be quite long and makes the display of the table in the email to which it is sent quite crowded. The link appears as the full address. I would prefer to have a label displayed so that when it's clicked the reader gets sent to the underlying link. I know how to create a labeled link in a regular HTML page. However, I'm trying various ways to embed the labeled URL into the table created by Create HTML Table. For example, I've something like this: <a href="https://google.com">Click for Google</a>. The table that is generated shows the link but ignores the label section.

Any advice?

SharePoint Workflow
SharePoint Workflow
SharePoint: A group of Microsoft Products and technologies used for sharing and managing content, knowledge, and applications.Workflow: An orchestrated and repeatable pattern of business activity, enabling data transformation, service provision, and information retrieval.
606 questions
{count} votes

Accepted answer
  1. Allen Xu_MSFT 13,831 Reputation points
    2021-12-27T01:47:51.367+00:00

    Hi @Nestor Holynskyj ,

    The key is that ‘<’ and so on are reserved characters in HTML, they are escaped as text, so they cannot be recognized. Finally I solved this issue by using expression replace(replace(replace(body('Create_HTML_table'),'&lt;','<'),'&quot;','"'),'&gt;','>') here:
    160516-image.png

    An email I got from above flow:
    160517-image.png

    ----------

    If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    1 person found this answer helpful.

1 additional answer

Sort by: Most helpful
  1. Nestor Holynskyj 21 Reputation points
    2021-12-27T14:44:30.937+00:00

    Outstanding! You absolutely rock! Saved me days of frustration... Thanks

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.