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 / Detecting a locked fil...
Power Automate
Unanswered

Detecting a locked file--other methods

(1) ShareShare
ReportReport
Posted on by 1,934 Moderator

I need to intercept locked files in SharePoint before they error out (SP can't update or delete files if they're locked).

annetoal_0-1654704880774.png

I have been using the Send a HTTP request to SharePoint with this code 

 

 

_api/web/GetFolderByServerRelativeURL('@{outputs('Get_file_properties')?['body/{Path}']}')/files/getbyurl('@{outputs('Get_file_properties')?['body/{Path}']}@{outputs('Get_file_properties')?['body/{FilenameWithExtension}']}')/LockedByUser

 

 

This works as long as the system thinks there is a LockedByUser, but occasionally it doesn't see the lock even though the file is open on someone else's computer. I think, but am not certain, this is because the login session has expired on the locking user's PC.

 

So, the locked file detection fails a certain percentage of times, and I am looking for a different parameter to query SharePoint about in the Send a HTTP request connector. Any suggestions or workaround would be most gratefully appreciated.

 

Thank you,

Anne

Categories:
I have the same question (0)

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
Vish WR Profile Picture

Vish WR 873

#2
Valantis Profile Picture

Valantis 822

#3
Haque Profile Picture

Haque 482

Last 30 days Overall leaderboard