I have some power automate flows. Running quite successfully for some time. Now, I have modified the flow. Added a couple of checks, but generally have not modified the file attributes of the list entry.
Meaning, I usually just read attributes from a file; (Sharepoint get item properties)
Do a bunch of checks, some calculations for field entries and the very last thing, is to write the changes to the file. (Sharepoint Update Item)
The biggest stumbling block I found was waiting, or checking if the file was open. I would attempt to write changes to said file, but error' FIle in use"
I did some code tweaks, and wrote a "SubProcedure" (Scope) to attempt to write to a file, if not (File in use), wait 10 and check again. (For about 4 hours)
that seems to have done the trick. I can now faithfully send file changes to the scope, and it is good.
Now, as of late, it is not good.
I am still getting the "File in use" error. Suprisingly, from the very service account doing the work.
What is the possibility that I may have two file handles open under the same service account ?
How long does it take to close that darn file handle ? (I am aware of the copy /. delete, but that wrecks a bunch of stuff)
IF I check if it is me (Service account), that has it open, can I force all my handles closed ?
Thoughts ?