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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Automate
Unanswered

Error in "Create HTML table"

(0) ShareShare
ReportReport
Posted on by

hello, I'm a newbie in power Automate, I have the Error mentioned in the title, I tried some solutions here, but I didn't understand well because it didn't apply very much to what I needed.

 

the Question is, im need to import a Table from excel, filter some Data, and send this data Filtered in HTML table to make more "visually pleasing"

 

follow the steps i created, if i'm taking too many turns please let me know how to simplify:

1- initialize a variable of String (i tried with array but get an error)

valcio_0-1681148966609.png

2- i imported the excel table and made a Parse JSON with body only

valcio_1-1681149036574.png

3- i made a loop to treat the data

valcio_2-1681149082742.pngvalcio_3-1681149102821.png

anyway its ends like this

valcio_4-1681149171441.png

 

the Error was "The 'from' property value in the 'table' action inputs is of type 'String'. The value must be of type 'Array'."

If i tried with an Array Variable this happens:

The property 'columns' must be specified unless the 'from' property value is an array of objects.

 

Please help me kk.

 

 

Categories:
I have the same question (0)
  • Venoo Profile Picture
    71 on at

    You don't have to parse JSON to list rows from the table.

    You can filter them the way they are.

     

    Then filtered results can be append in their existing format which should be usable by html table format.

  • Community Power Platform Member Profile Picture
    on at

    can show me how to do that? i search i little bit here and didn't find anything

  • Venoo Profile Picture
    71 on at

    1. Set Variable type to Array from String

    2. Ignore Parse Json for now.

    3. In a condition, use dynamic content from excel like here

    Venoo_1-1681156553038.png

     

    4. Change append to string variable into append to array variable

    5. Hook the appended variable to html table

  • grantjenkins Profile Picture
    11,063 Moderator on at

    Hopefully this is what you're looking for.

     

    Question: how many items are in your Excel Table?

     

    A few notes about retrieving data from Excel.

    • By default, List rows present in a table will only return a maximum of 256 items. If you need more than this, you can set Top Count to 5000 (maximum). If you have more than 5000 items, you will also need to turn on Pagination and set a Threshold.
    • The Filter Query can't use field names with spaces in them.
    • The Filter Query can only have a single condition.

     

    For this example, I'm using the following Excel Table (not all fields/rows shown).

    grantjenkins_0-1681193970951.png

     

    See full flow below. I'll go into each of the actions.

    grantjenkins_1-1681194002456.png

     

    List rows present in a table will initially retrieve all the items from my Excel Table. Because I have more than 256 rows, I've set the Top Count to 5000 so it will retrieve up to 5000 items.

    grantjenkins_2-1681194135520.png

     

    Filter array uses the output from List rows present in a table and has two conditions. Segment is equal to Government and Country is equal to France. Because we have more than one condition, we need to Edit in advanced mode and add our query. See query below.

    //You would change this to what your conditions are
    
    @and(
     equals(item()?['Segment'], 'Government'),
     equals(item()?['Country'], 'France')
    )

    grantjenkins_3-1681194256252.png

     

    You could add a Parse JSON action here and setup the schema. However, I've just gone with working directly from the Filter array to build up my HTML table.

     

    Create HTML table uses the output from Filter array and maps out the fields I want to display.

    //Segment
    item()?['Segment']
    
    //Country
    item()?['Country']
    
    //Product
    item()?['Product']
    
    //Units Sold
    item()?['Units Sold']
    
    //Other fields that I want
    item()?['Field Name']

    grantjenkins_4-1681194643339.png

     

    Style HTML table is a Compose action (just renamed it) that contains some CSS for styling the HTML table (make it look nicer in the email).

    <style>
     table {
     border-collapse: collapse;
     }
     table td,
     table th {
     border: 1px solid #ddd;
     padding: 6px 20px;
     text-align: left;
     }
     table th {
     background-color: #1C6EA4;
     color: white;
     }
    </style>

     

    Send an email uses the output from Style HTML table and Create HTML table in the Body.

    grantjenkins_5-1681194725007.png

     

    Below is the email received after the flow runs.

    grantjenkins_6-1681194827630.png

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Automate

#1
Michael E. Gernaey Profile Picture

Michael E. Gernaey 501 Super User 2025 Season 2

#2
Tomac Profile Picture

Tomac 323 Moderator

#3
abm abm Profile Picture

abm abm 237 Most Valuable Professional

Last 30 days Overall leaderboard