web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Pre Built Expressions ...
Power Automate
Answered

Pre Built Expressions in HTML to auto populate with flow

(0) ShareShare
ReportReport
Posted on by 62
Hi,
 
I have a flow that uses expressions to populate different parts of html dynamically.  What I am tring to do is have a bunch of HTML templates saved to a sharepoint doc library and the flow will get the file content of that html file and replace the expressions with what they are suppose to represent.
 
Example of what the contents of the HTML file in sharepoint looks like.
    <table>
        <tr>
            <th>Pour Date</th>
            <td colspan="3">@{body('Parse_JSON')?[0]['ResponseDate']}</td>
        </tr>
        <tr>
            <th>Pour Number</th>
            <td>@{body('Parse_JSON')?[1]['ResponseText']}</td>
            <th>Pour Name</th>
            <td>@{body('Parse_JSON')?[2]['ResponseText']}</td>
        </tr>
        <tr>
            <th>Engineer</th>
            <td colspan="3">@{body('Parse_JSON')?[3]['ResponseText']}</td>
        </tr>
        <tr>
            <th>Sub-Contractor</th>
            <td colspan="3">@{body('Parse_JSON')?[4]['ResponseText']}</td>
        </tr>
        <tr>
            <th>Concrete Supplier</th>
            <td>@{body('Parse_JSON')?[5]['ResponseText']}</td>
            <th>Contact at the plant</th>
            <td><job_workflow 1258183 value></td>
        </tr>
 
 
So I would like the flow to auto populate the parts in bold.
 
Flow works fine when I just paste the html into a compose action, but since I could have over 100 different HTML templates I thought I could read the contents of the template into flow and it would populate the same way.
Categories:
I have the same question (0)
  • Verified answer
    Chriddle Profile Picture
    8,685 Super User 2026 Season 1 on at
    No, that doesn't work. You can't add (and execute) expressions at runtime.
     
    But you can do string replacements within the HTML templates like this:
    replace(
    	<your_HTML_template>,
    	'@{body(''Parse_JSON'')?[2][''ResponseText'']}',
    	body('Parse_JSON')?[2]['ResponseText']
    )
     
     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Haque Profile Picture

Haque 550

#2
Valantis Profile Picture

Valantis 390

#3
11manish Profile Picture

11manish 348

Last 30 days Overall leaderboard