Skip to main content

Notifications

Power Automate - Power Automate Desktop
Unanswered

Update failing with 'file locked'

(1) ShareShare
ReportReport
Posted on by 267
I have a flow where I am processing new invoices for approximately 50 accounts. 
When a new invoice arrives I am getting the invoice account number and transactions, then adding those new transactions to the appropriate invoice 'master' excel file.  
 
as the desktop flow action 'add a new row into a table' can't be used with a dynamic file location I need to build in a few extra steps
 
below is the part of the flow that is causing a problem. 
At this point, I have processed the new invoice. The two steps get the existing invoice excel and copy it to a 'static' template file so the 'add a new row' can update it. 
 
For some reason, the 'add a new row' step appears to lock the template file. I can no longer edit it in the browser. The flow also fails when it tries to run. 
If I leave the flow overnight, it will run again, but then fails after a short while. 
 
Categories:
  • Deenuji_Loganathan_ Profile Picture
    Deenuji_Loganathan_ 6,087 on at
    Update failing with 'file locked'
    Hi,
     
    Could you please a complete flow screenshot so that I can better understand your issue?
     
    Thanks,
    Deenuji Loganathan 👩‍💻
    Power Automate Desktop Community Champion 🤖
     
  • David_MA Profile Picture
    David_MA 9,039 on at
    update fail failing with 'file locked'
    I don't use Power Automate Desktop, but I can tell you how I handle this in a regular Power Automate flow. Do the following:
    1. Create a Boolean variable named Updated and set the initial value to false.
    2. Add a Do until action and set it to run until Update is true.
    3. Within the Do until action, add the action to update the spreadsheet.
    4. Below this action, add two parallel actions.
      1. The first will be an Update variable action where you update the Updated variable to true.
        1. Configure this to only run if the Excel action succeeds.
      2. The other will be a delay. Set the delay to five minutes.
        1. Configure this to only run if the Excel action fails.

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

Microsoft Kickstarter Events…

Register for Microsoft Kickstarter Events…

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Announcing Forum Attachment Improvements!

We're excited to announce that attachments for replies in forums and improved…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 145,580

#2
RandyHayes Profile Picture

RandyHayes 76,287

#3
Pstork1 Profile Picture

Pstork1 64,909

Leaderboard