cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

A workaround for current limitations of flow actions in SharePioint.

As many of you know, currently Flow has limitations with SharePoint integration that makes many common real-world scenarios difficult to achieve, including: 

  • The Create File action provides no way to update library metadata when uploading a file, nor does it return the item ID of the newly created file
  • The Create Item action provides access to metadata but only works on lists
  • The Update Item action works on document libraries, but requires the item ID of the document to do so. Since Create File does not provide it, we have no reference to the newly created file
  • The Get Items function allows you to search a list/library for content, but cannot match on File Name

Basically this means it's hard to upload a file to SharePoint via flow and then set metadata on it. 

 

Given this is such a common scenario, I came up with this workaround. This method is not ideal, but will work without a problem for many scenarios. Basically the method is:

 

  1. Use Create File action to upload a file
  2. Use the Get Items action to bring me back the metadata for the most recently created file in the library
  3. Grab the ID from step 2
  4. Use the Update Item action to set the metadata on the recently uploaded image.

I fully document the approach here as part of a series of posts that shows how to call an API in PowerApps and pass the data back to Flow...

 

http://www.cleverworkarounds.com/2017/07/07/hows-the-weather-using-a-public-api-with-powerapps-part-...

 

Hope this helps someone, and hopefully the need for such a method is eliminated sooner rather than later...

 

Paul

1 ACCEPTED SOLUTION

Accepted Solutions
Anonymous
Not applicable

Actually I just found a much better way to do it that has helped me go bulk photo uploads from PowerApps with tagging to SharePoint 🙂

http://www.cleverworkarounds.com/2017/07/14/the-currently-best-way-to-update-sharepoint-document-met...

The gist of it is that the web service used by the Get Items action is different to the styandard SharePoint REST endpoint and certain things don't work... The filter to apply to the list is:

 

FileLeafRef eq '[File name from previous flow action]'

 

Paul

View solution in original post

4 REPLIES 4
v-micsh-msft
Community Support
Community Support

Hi @Anonymous,

 

Thanks for the sharing.

 

For Flow related blog, you may also consider posting in the following site:

https://powerusers.microsoft.com/t5/Microsoft-Flow-Community-Blog/bg-p/FlowBlog

 

Regards,

Michael

Community Support Team _ Michael Shao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
Not applicable

I'd be happy to post to that blog, but I can't see how? Am I msising something obvious?

Hi @Anonymous,

 

Follow the blog below:

Introducing the Microsoft Flow Community Blog

Quoted:

"

Everyone is welcome to contribute! To get started, simply message me, @JessicaC, with a rough title for your post and a couple of sentences to describe your topic, or a link if you want to excerpt a post that already exists on your own blog. Together we’ll preview how your post will look once it’s done, and set a publication date.

"

Regards,

Michael

Community Support Team _ Michael Shao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
Not applicable

Actually I just found a much better way to do it that has helped me go bulk photo uploads from PowerApps with tagging to SharePoint 🙂

http://www.cleverworkarounds.com/2017/07/14/the-currently-best-way-to-update-sharepoint-document-met...

The gist of it is that the web service used by the Get Items action is different to the styandard SharePoint REST endpoint and certain things don't work... The filter to apply to the list is:

 

FileLeafRef eq '[File name from previous flow action]'

 

Paul

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

May UG Leader Call Carousel 768x460.png

June User Group Leader Call

Join us on June 28 for our monthly User Group leader call!

MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

Power Automate Designer Feedback_carousel.jpg

Help make Flow Design easier

Are you new to designing flows? What is your biggest struggle with Power Automate Designer? Help us make it more user friendly!

Top Solution Authors
Top Kudoed Authors
Users online (1,530)