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 / How to insert row to e...
Power Automate
Unanswered

How to insert row to excel properly in Power Automate Desktop?

(0) ShareShare
ReportReport
Posted on by 4

I am extracting data from web(data are come from the same webPage) and I want to put them into an excel file

ken7_0-1630052737877.png

I have done this steps, but when I use for each to loop through the merge list, some of the data in dataFromWebPage that stored in the merge list will lost.

There should be 12 record in dataFromWebPage and 7 record in dataFromWebPage2 , but the final outcome in excel will be 13 rows only, anyone know how to deal with it?

ken7_1-1630052781341.png

 

  • Daniel_Pa Profile Picture
    244 on at

    Can you provide some more information?

    Why are you using two "Extract data from web page"? Does the variables DataFromWebPage and DataFromWebPage2 contain the expected number of entries?

    Can you share an image from your variables pane and the content of the two variables?

     

    What is the purpose of inserting new lines? Are you filling in a spreadsheet already containing data? If not, you can just write the list into the desired cell, and it will fill in the values downwards.

  • ken7 Profile Picture
    4 on at

    sure, I am trying to scrap data from a public webpage, but the web page is kind of dynamic, when I expand one section, the other section will be collapse, I am new to power desktop and I can't find a better way to select all of the information I want( i.e all the subtitle and last update time that shows only when section expanded)

    ken7_1-1630055963790.png

    Here is the flow variables

    ken7_0-1630055902619.png

    ken7_3-1630056472583.pngken7_4-1630056489532.png

     

    variable value in output list

    ken7_2-1630056178410.png

    and actual outcome in excel

    ken7_5-1630056574581.png

     

    How can I achieve by filling in the desired cell? Each record have two columns, would it be autofill also?

  • Daniel_Pa Profile Picture
    244 on at

    Ahh.. The issue seems to be you are using "Merge list" to merge two "Data tables" - thus you list will contain only two items, the two tables.

    Thus, you are only looping twice, first inserting the the 12 item table, and then shifting it down once, before inserting the 7 item list on top of it.

     

    Since it seems you are only working with those two list, you could "Write to Excel worksheet" on A1, then "Get first free column/row from Excel" and write the second table to the first free row.

    If you need more tables eventually, you could use you loop to get the first free row for each table you want to write and then write to that location.

     

    I hope this makes sense, if not, let me know and i will try to illustrate it.

  • ken7 Profile Picture
    4 on at

    Thx, this seems overall ok now, however there will be strange blank rows created, do you know what leads to the problem?

    ken7_0-1630058269422.png

     

  • Daniel_Pa Profile Picture
    244 on at

    Are you reusing the same spreadsheet? Make sure to select the rows and delete them, not just the content of the cells.

    Alternatively, try using the "Launch Excel" with at blank sheet.

     

    If that doesn't work, please send a screenshot of the process and I'll take a look.

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
David_MA Profile Picture

David_MA 227 Super User 2026 Season 2

#2
11manish Profile Picture

11manish 221 Super User 2026 Season 2

#3
Mohsin Ali Profile Picture

Mohsin Ali 132

Last 30 days Overall leaderboard