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 / File Approval with sha...
Power Automate
Unanswered

File Approval with sharing files

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

Hello,

 

I have somme issues with a flow for file approval. This is my first one, so I have next to no clues what I'm doing with flows (other than knowing my way around programming). So, I started with the tempate Request approval in Teams for a selected item in SharePoint. After figuring out that an item is not a file and I need to switch to a For a selected file trigger, all went well; changed the fields here and there in the emails, approval with multi approvers, etc. So that work so far.

 

Then I needed to add a shared link inside my organisation for people that doesn't have access to the SharePoint site to start with. However, I also need to remove sharing as soon as the flow is done. Easy I though, just add the Create sharing link for a file or folder action, then when the approval is done, add the Stop sharing an item or a file action. Configured them with the result ID (@triggerBody()?['entity']?['ID']) from the trigger for both of them. Run a test, sharing link is working no issues there. But the flow fail at the stop sharing action with the result below. Seems that I am forbidden to stop sharing a file. Isn't strange that I can create a sharing, but not stop it? Had other issues with also moving the file on another test (wanted to move the file in another folder when approval is done), but the Move file action that ask the file ID doesn't seem to accept the same file ID (@triggerBody()?['entity']?['ID']) used for sharing a file, it doesn't find the file for moving.

 

Stop sharing error:

 

 

 

 

{
 "status": 403,
 "message": "Exception of type 'Microsoft.SharePoint.SPConnectorException' was thrown.\r\nclientRequestId: xxxxxxxxxxxxxxxxxxxxxxxxxxx\r\nserviceRequestId: xxxxxxxxxxxxxxxx"
}

 

 

 

 

 

File moving error:

 

 

 

 

{
 "status": 400,
 "message": "Nous n’avons pas pu vérifier l’existence de l’objet source à l’adresse « https://xxxxxxxxxxxxxxxxxxx » en raison de l’erreur « The system cannot find the file specified. (Exception from HRESULT: 0x80070002) ».\r\nclientRequestId: xxxxxxxxxxxxxxxx\r\nserviceRequestId: xxxxxxxxxxxxxxxxxx"
}

 

 

 

 

 

Any idea?

 

Thanks!

Categories:
I have the same question (0)
  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

     

    Could you share the screenshot of the flow configuration?

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    I decided to abandon using Power Automate for the moment, too much of my official work to take time to learn Power Automate and make it work.

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Ok, going back finally... I worked with our IT to bypass the sharing process, everybody have access, so only need for them to have the link of the file. However, when I do the following "For a selected file", everything has the right data except the "Link to element" field, using the "itemUrl" from "For a selected file", it seems to generate a URL with somewhat valid data (the URL has data related to the file in question), but it load a blank website, not showing the file. Any idea where to look for debug?

     

    bpare_0-1593609967902.png

     

  • sadiku-adetola Profile Picture
    2 on at

    I found this article useful. It had to do with making sure the user used for the SharePoint connection has proper permission to the list o library you are working in. So add the user to the list owners group.

     

    https://powerusers.microsoft.com/t5/I-Found-A-Bug/Cannot-stop-sharing-an-item/td-p/929925

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 April Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Vish WR Profile Picture

Vish WR 791

#2
Valantis Profile Picture

Valantis 568

#3
Haque Profile Picture

Haque 535

Last 30 days Overall leaderboard