0

This is happening constantly the last few days. The flow pulls the attachment from an email when arrives to a folder. The attachments is a .xlsx. Then the flow creates a table in the same sheet, then it iterates each row that is not empty and it passes that values to a Apply to each block.

This is where it fails, I have to edit the Flow every time it fails, and just select again the same file, I mean, nothing else changes. enter image description here

This is the error

enter image description here

And this is the flow:

enter image description here

enter image description here

1
  • I think it is throwing error because it is unable to read the specified "table" in the excel file. May 25, 2021 at 3:24

2 Answers 2

1

I frequently run into this issue, and have found it to stem from one of two root causes.

#1: If you're posting to the document library a new "status.xlsx" file each time, then when you "select again the same file" you're actually selecting a different file--even if you're reusing the same filename. In the flow action, instead of selecting a file use dynamic content to enter the fileID and table name as custom values.

#2: Often, it seems that a flow believes an action within a file on OneDrive or SharePoint is complete before it's actually complete. I've worked around this lag by embedding delays (e.g., 30 seconds) in a flow between actions like creating a table and getting the rows from that table.

Update: Re #2, here's another technique I just tried and seemed to work upon initial testing--loop until file/table access is confirmed. Power Automate flow actions: initialize variable as false; within do until loop, attempt to perform desired action followed by action to set variable to true only upon success of desired action

1
  • Yes, I actually forgot about this question. I found something usefull this the Excel MS docs: "An Excel file may be locked for an update or delete up to 6 minutes since the last use of the connector." So I added a 10mins delay just to be sure. Thank you, David. Jun 11, 2021 at 21:33
1

I was able to solve this by adding a delay. The MS Docs says that an Excel file may be locked for an update or delete up to 6 minutes since the last use of the connector. So what I did is to add a Delay of 10 minutes to be sure that the file is available when the List rows present in a table does its thing.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.